Re: [PATCH V4] Fix pointer cast for 32 bits arch

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Apr 16, 2015 at 06:05:27PM +0100, Alan Cox wrote:
> Its a 64 on 64 or 32 on 32 virtual machine. Goldfish is used for Android
> emulation for all the system level phone emulation tools. On the
> emulation side it provides an interface for the emulated OS but makes no
> effort to emulate it as if it was a real hardware. If you think of it as
> a funky emulator interface all is good. If you think about it as
> "hardware" you've got the wrong model and chunks of Goldfish make less
> sense.
> 

Ah.  Ok.  That makes sense.

Peter maybe the fix is to make a different function:

static inline void gf_write_dma_addr(dma_addr_t addr, void __iomem *portl,
				     void __iomem *porth)
{
        writel((u32)data, portl);
#ifdef CONFIG_ARCH_DMA_ADDR_T_64BIT
        writel(data >> 32, porth);
#endif
}

Something like that.

The gf_write_ptr() function patch you wrote preserves the current
behavior, but the current behavior is buggy, (I think) so we need
both gf_write_dma_addr() and gf_write_ptr().

regards,
dan carpenter

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux