* [-next] comedi I/O accessor name clashes
@ 2014-06-20 11:07 Geert Uytterhoeven
2014-06-20 11:12 ` Ian Abbott
0 siblings, 1 reply; 4+ messages in thread
From: Geert Uytterhoeven @ 2014-06-20 11:07 UTC (permalink / raw)
To: H Hartley Sweeten, Ian Abbott, Greg KH
Cc: linux-kernel, driverdevel, Linux-Next
commit 9c340ac934dbbfd46e776465b08391baac32d486
Author: H Hartley Sweeten <hsweeten@visionengravers.com>
Date: Thu May 29 10:56:32 2014 -0700
staging: comedi: ni_stc.h: add read/write callbacks to struct ni_private
--- a/drivers/staging/comedi/drivers/ni_stc.h
+++ b/drivers/staging/comedi/drivers/ni_stc.h
@@ -1421,6 +1421,13 @@ struct ni_board_struct {
#define NUM_GPCT 2
struct ni_private {
+ uint8_t (*readb)(struct comedi_device *, int reg);
+ uint16_t (*readw)(struct comedi_device *, int reg);
+ uint32_t (*readl)(struct comedi_device *, int reg);
+ void (*writeb)(struct comedi_device *, uint8_t value, int reg);
+ void (*writew)(struct comedi_device *, uint16_t value, int reg);
+ void (*writel)(struct comedi_device *, uint32_t value, int reg);
+
uint16_t (*stc_readw)(struct comedi_device *, int reg);
uint32_t (*stc_readl)(struct comedi_device *, int reg);
void (*stc_writew)(struct comedi_device *, uint16_t value, int reg);
However, on several architectures, writel() and friends are macros, causing:
drivers/staging/comedi/drivers/ni_atmio.c:318:38: error: macro
"writew" passed 3 arguments, but takes just 2
m68k http://kisskb.ellerman.id.au/kisskb/buildresult/11346953/
s390 kisskb.ellerman.id.au/kisskb/buildresult/11347163/
sparc64 kisskb.ellerman.id.au/kisskb/buildresult/11347152/
xtensa http://kisskb.ellerman.id.au/kisskb/buildresult/11346651/
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [-next] comedi I/O accessor name clashes
2014-06-20 11:07 [-next] comedi I/O accessor name clashes Geert Uytterhoeven
@ 2014-06-20 11:12 ` Ian Abbott
2014-06-20 11:20 ` Geert Uytterhoeven
0 siblings, 1 reply; 4+ messages in thread
From: Ian Abbott @ 2014-06-20 11:12 UTC (permalink / raw)
To: Geert Uytterhoeven, H Hartley Sweeten, Greg KH
Cc: linux-kernel, driverdevel, Linux-Next
On 2014-06-20 12:07, Geert Uytterhoeven wrote:
> commit 9c340ac934dbbfd46e776465b08391baac32d486
> Author: H Hartley Sweeten <hsweeten@visionengravers.com>
> Date: Thu May 29 10:56:32 2014 -0700
>
> staging: comedi: ni_stc.h: add read/write callbacks to struct ni_private
>
> --- a/drivers/staging/comedi/drivers/ni_stc.h
> +++ b/drivers/staging/comedi/drivers/ni_stc.h
> @@ -1421,6 +1421,13 @@ struct ni_board_struct {
> #define NUM_GPCT 2
>
> struct ni_private {
> + uint8_t (*readb)(struct comedi_device *, int reg);
> + uint16_t (*readw)(struct comedi_device *, int reg);
> + uint32_t (*readl)(struct comedi_device *, int reg);
> + void (*writeb)(struct comedi_device *, uint8_t value, int reg);
> + void (*writew)(struct comedi_device *, uint16_t value, int reg);
> + void (*writel)(struct comedi_device *, uint32_t value, int reg);
> +
> uint16_t (*stc_readw)(struct comedi_device *, int reg);
> uint32_t (*stc_readl)(struct comedi_device *, int reg);
> void (*stc_writew)(struct comedi_device *, uint16_t value, int reg);
>
> However, on several architectures, writel() and friends are macros, causing:
>
> drivers/staging/comedi/drivers/ni_atmio.c:318:38: error: macro
> "writew" passed 3 arguments, but takes just 2
>
> m68k http://kisskb.ellerman.id.au/kisskb/buildresult/11346953/
> s390 kisskb.ellerman.id.au/kisskb/buildresult/11347163/
> sparc64 kisskb.ellerman.id.au/kisskb/buildresult/11347152/
> xtensa http://kisskb.ellerman.id.au/kisskb/buildresult/11346651/
>
> Gr{oetje,eeting}s,
>
> Geert
Thanks, but Hartley has already fixed it and Greg has applied it to his
staging-next branch. It should wend it's merry way to linux-next in the
not-too-distant future.
Cheers,
Ian.
--
-=( Ian Abbott @ MEV Ltd. E-mail: <abbotti@mev.co.uk> )=-
-=( Tel: +44 (0)161 477 1898 FAX: +44 (0)161 718 3587 )=-
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [-next] comedi I/O accessor name clashes
2014-06-20 11:12 ` Ian Abbott
@ 2014-06-20 11:20 ` Geert Uytterhoeven
2014-06-20 16:20 ` Hartley Sweeten
0 siblings, 1 reply; 4+ messages in thread
From: Geert Uytterhoeven @ 2014-06-20 11:20 UTC (permalink / raw)
To: Ian Abbott
Cc: H Hartley Sweeten, Greg KH, linux-kernel, driverdevel, Linux-Next
Hi Ian,
On Fri, Jun 20, 2014 at 1:12 PM, Ian Abbott <abbotti@mev.co.uk> wrote:
>> drivers/staging/comedi/drivers/ni_atmio.c:318:38: error: macro
>> "writew" passed 3 arguments, but takes just 2
> Thanks, but Hartley has already fixed it and Greg has applied it to his
> staging-next branch. It should wend it's merry way to linux-next in the
> not-too-distant future.
Thanks, good to hear that!
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: [-next] comedi I/O accessor name clashes
2014-06-20 11:20 ` Geert Uytterhoeven
@ 2014-06-20 16:20 ` Hartley Sweeten
0 siblings, 0 replies; 4+ messages in thread
From: Hartley Sweeten @ 2014-06-20 16:20 UTC (permalink / raw)
To: Geert Uytterhoeven, Ian Abbott
Cc: Greg KH, linux-kernel, driverdevel, Linux-Next
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 715 bytes --]
On Friday, June 20, 2014 4:20 AM, Geert Uytterhoeven wrote:
> On Fri, Jun 20, 2014 at 1:12 PM, Ian Abbott <abbotti@mev.co.uk> wrote:
>>> drivers/staging/comedi/drivers/ni_atmio.c:318:38: error: macro
>>> "writew" passed 3 arguments, but takes just 2
>
>> Thanks, but Hartley has already fixed it and Greg has applied it to his
>> staging-next branch. It should wend it's merry way to linux-next in the
>> not-too-distant future.
>
> Thanks, good to hear that!
Geert / Ian,
The patches to fix this are in next-20140620.
Sorry for the trouble,
Hartley
ÿôèº{.nÇ+·®+%Ëÿ±éݶ\x17¥wÿº{.nÇ+·¥{±þG«éÿ{ayº\x1dÊÚë,j\a¢f£¢·hïêÿêçz_è®\x03(éÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?¨èÚ&£ø§~á¶iOæ¬z·vØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?I¥
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-06-20 16:20 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-20 11:07 [-next] comedi I/O accessor name clashes Geert Uytterhoeven
2014-06-20 11:12 ` Ian Abbott
2014-06-20 11:20 ` Geert Uytterhoeven
2014-06-20 16:20 ` Hartley Sweeten
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®