Re: [PATCH] sparc: io_64.h: Replace io function-link macros

2015-01-30 Thread David Miller
From: Ricardo Ribalda Delgado Date: Thu, 29 Jan 2015 15:52:02 +0100 > Function like macros cannot be assigned to function pointers. This patch > convert the function-like macros into object-macros, that the > precompiler will replace with the name of the final function. > > With this patch this

Re: [PATCH] sparc: io_64.h: Replace io function-link macros

2015-01-30 Thread David Miller
From: Ricardo Ribalda Delgado ricardo.riba...@gmail.com Date: Thu, 29 Jan 2015 15:52:02 +0100 Function like macros cannot be assigned to function pointers. This patch convert the function-like macros into object-macros, that the precompiler will replace with the name of the final function.

Re: [PATCH] sparc: io_64.h: Replace io function-link macros

2015-01-29 Thread Ricardo Ribalda Delgado
Hello Arnd On Thu, Jan 29, 2015 at 5:02 PM, Arnd Bergmann wrote: > I suspect such code is broken on a lot of platforms: > > arch/alpha/include/asm/io.h:#define ioread32be(p) be32_to_cpu(ioread32(p)) > arch/arm/include/asm/io.h:#define ioread32be(p) ({ __u32 __v = > be32_to_cpu((__force

Re: [PATCH] sparc: io_64.h: Replace io function-link macros

2015-01-29 Thread Arnd Bergmann
On Thursday 29 January 2015 15:52:02 Ricardo Ribalda Delgado wrote: > Function like macros cannot be assigned to function pointers. This patch > convert the function-like macros into object-macros, that the > precompiler will replace with the name of the final function. > > With this patch this

[PATCH] sparc: io_64.h: Replace io function-link macros

2015-01-29 Thread Ricardo Ribalda Delgado
Function like macros cannot be assigned to function pointers. This patch convert the function-like macros into object-macros, that the precompiler will replace with the name of the final function. With this patch this kind of code will work: if (priv->mode_big_endian) priv.read =

Re: [PATCH] sparc: io_64.h: Replace io function-link macros

2015-01-29 Thread Ricardo Ribalda Delgado
Hello Arnd On Thu, Jan 29, 2015 at 5:02 PM, Arnd Bergmann a...@arndb.de wrote: I suspect such code is broken on a lot of platforms: arch/alpha/include/asm/io.h:#define ioread32be(p) be32_to_cpu(ioread32(p)) arch/arm/include/asm/io.h:#define ioread32be(p) ({ __u32 __v =

[PATCH] sparc: io_64.h: Replace io function-link macros

2015-01-29 Thread Ricardo Ribalda Delgado
Function like macros cannot be assigned to function pointers. This patch convert the function-like macros into object-macros, that the precompiler will replace with the name of the final function. With this patch this kind of code will work: if (priv-mode_big_endian) priv.read =

Re: [PATCH] sparc: io_64.h: Replace io function-link macros

2015-01-29 Thread Arnd Bergmann
On Thursday 29 January 2015 15:52:02 Ricardo Ribalda Delgado wrote: Function like macros cannot be assigned to function pointers. This patch convert the function-like macros into object-macros, that the precompiler will replace with the name of the final function. With this patch this kind