Felipe Balbi | 5 Dec 2008 22:53

Re: [irda-users] [PATCH] OMAP IrDA driver

On Fri, Dec 05, 2008 at 03:18:10PM +0530, Trilok Soni wrote:
> +struct omap_irda {
> +	unsigned char open;
> +	int speed;		/* Current IrDA speed */
> +	int newspeed;
> +
> +	struct net_device_stats stats;
> +	struct irlap_cb *irlap;
> +	struct qos_info qos;
> +
> +	int rx_dma_channel;
> +	int tx_dma_channel;
> +
> +	dma_addr_t rx_buf_dma_phys;	/* Physical address of RX DMA buffer */
> +	dma_addr_t tx_buf_dma_phys;	/* Physical address of TX DMA buffer */
> +
> +	void *rx_buf_dma_virt;		/* Virtual address of RX DMA buffer */
> +	void *tx_buf_dma_virt;		/* Virtual address of TX DMA buffer */

should these two be void __iomem * ?

> +
> +	struct device *dev;
> +	struct omap_irda_config *pdata;
> +};
> +
> +static inline void uart_reg_out(int idx, u8 val)
> +{
> +	omap_writeb(val, idx);

(Continue reading)

Trilok Soni | 22 Dec 2008 12:24
Picon

Re: [irda-users] [PATCH] OMAP IrDA driver

Hi Felipe,

Sorry for delayed reply.

>> +
>> +     void *rx_buf_dma_virt;          /* Virtual address of RX DMA buffer */
>> +     void *tx_buf_dma_virt;          /* Virtual address of TX DMA buffer */
>
> should these two be void __iomem * ?

Agreed.

>
>> +
>> +     struct device *dev;
>> +     struct omap_irda_config *pdata;
>> +};
>> +
>> +static inline void uart_reg_out(int idx, u8 val)
>> +{
>> +     omap_writeb(val, idx);
>
> __raw_writeb(), pass a reference to struct omap_irda here so you'd have
> access to a void __iomem *base (read below).

Agreed.

>> + */
>> +static void omap_irda_rx_dma_callback(int lch, u16 ch_status, void *data)
>> +{
(Continue reading)


Gmane