sg_dma_len(sg) = priv->fifo_size;
sg_set_page(&priv->sg_rx, virt_to_page(priv->rx_buf_virt),
- sg_dma_len(sg), (int)priv->rx_buf_virt & ~PAGE_MASK);
+ sg_dma_len(sg), (unsigned long)priv->rx_buf_virt &
+ ~PAGE_MASK);
sg_dma_address(sg) = priv->rx_buf_dma;
int ret;
unsigned int iobase;
unsigned int mapbase;
- unsigned int rxbuf;
+ unsigned char *rxbuf;
int fifosize, base_baud;
static int num;
if (priv == NULL)
goto init_port_alloc_err;
- rxbuf = __get_free_page(GFP_KERNEL);
+ rxbuf = (unsigned char *)__get_free_page(GFP_KERNEL);
if (!rxbuf)
goto init_port_free_txbuf;
priv->iobase = iobase;
priv->pdev = pdev;
priv->tx_empty = 1;
- priv->rxbuf.buf = (unsigned char *)rxbuf;
+ priv->rxbuf.buf = rxbuf;
priv->rxbuf.size = PAGE_SIZE;
priv->fifo_size = fifosize;
return priv;
init_port_hal_free:
- free_page(rxbuf);
+ free_page((unsigned long)rxbuf);
init_port_free_txbuf:
kfree(priv);
init_port_alloc_err:
{
uart_remove_one_port(&pch_uart_driver, &priv->port);
pci_set_drvdata(priv->pdev, NULL);
- free_page((unsigned int)priv->rxbuf.buf);
+ free_page((unsigned long)priv->rxbuf.buf);
}
static void pch_uart_pci_remove(struct pci_dev *pdev)