* [PATCH 1/9] stringify: add HEX_STRING() @ 2011-07-10 19:51 Randy Dunlap 2011-07-13 21:05 ` Mauro Carvalho Chehab 2011-07-13 21:49 ` Arnaud Lacombe 0 siblings, 2 replies; 18+ messages in thread From: Randy Dunlap @ 2011-07-10 19:51 UTC (permalink / raw) To: lkml; +Cc: linux-kbuild, linux-media, mchehab From: Randy Dunlap <rdunlap@xenotime.net> Add HEX_STRING(value) to stringify.h so that drivers can convert kconfig hex values (without leading "0x") to useful hex constants. Several drivers/media/radio/ drivers need this. I haven't checked if any other drivers need to do this. Alternatively, kconfig could produce hex config symbols with leading "0x". Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> --- include/linux/stringify.h | 7 +++++++ 1 file changed, 7 insertions(+) NOTE: The other 8 patches are on lkml and linux-media mailing lists. --- linux-next-20110707.orig/include/linux/stringify.h +++ linux-next-20110707/include/linux/stringify.h @@ -9,4 +9,11 @@ #define __stringify_1(x...) #x #define __stringify(x...) __stringify_1(x) +/* + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, + * but kconfig does not put a leading "0x" on them. + */ +#define HEXSTRINGVALUE(h, value) h##value +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) + #endif /* !__LINUX_STRINGIFY_H */ ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-10 19:51 [PATCH 1/9] stringify: add HEX_STRING() Randy Dunlap @ 2011-07-13 21:05 ` Mauro Carvalho Chehab 2011-07-13 21:11 ` Randy Dunlap 2011-07-13 22:04 ` Randy Dunlap 2011-07-13 21:49 ` Arnaud Lacombe 1 sibling, 2 replies; 18+ messages in thread From: Mauro Carvalho Chehab @ 2011-07-13 21:05 UTC (permalink / raw) To: Randy Dunlap; +Cc: lkml, linux-kbuild, linux-media Em 10-07-2011 16:51, Randy Dunlap escreveu: > From: Randy Dunlap <rdunlap@xenotime.net> > > Add HEX_STRING(value) to stringify.h so that drivers can > convert kconfig hex values (without leading "0x") to useful > hex constants. > > Several drivers/media/radio/ drivers need this. I haven't > checked if any other drivers need to do this. > > Alternatively, kconfig could produce hex config symbols with > leading "0x". Hi Randy, After applying patch 1/9 and 2/9 over 3.0-rc7+media patches, I'm now getting this error: drivers/media/radio/radio-aimslab.c:52:1: error: invalid suffix "x20f" on integer constant $ grep 20f .config CONFIG_RADIO_RTRACK_PORT=20f $ gcc --version gcc (GCC) 4.4.5 20110214 (Red Hat 4.4.5-6) Before this patch, this were working (or, at least, weren't producing any error). Perhaps the breakage on your compilation happened due to another patch at the tree? If so, the better would be to apply this patch series together with the ones that caused the breakage, to avoid bisect troubles. > > Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> > --- > include/linux/stringify.h | 7 +++++++ > 1 file changed, 7 insertions(+) > > NOTE: The other 8 patches are on lkml and linux-media mailing lists. > > --- linux-next-20110707.orig/include/linux/stringify.h > +++ linux-next-20110707/include/linux/stringify.h > @@ -9,4 +9,11 @@ > #define __stringify_1(x...) #x > #define __stringify(x...) __stringify_1(x) > > +/* > + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, > + * but kconfig does not put a leading "0x" on them. > + */ > +#define HEXSTRINGVALUE(h, value) h##value > +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) > + > #endif /* !__LINUX_STRINGIFY_H */ ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-13 21:05 ` Mauro Carvalho Chehab @ 2011-07-13 21:11 ` Randy Dunlap 2011-07-13 22:04 ` Randy Dunlap 1 sibling, 0 replies; 18+ messages in thread From: Randy Dunlap @ 2011-07-13 21:11 UTC (permalink / raw) To: Mauro Carvalho Chehab; +Cc: lkml, linux-kbuild, linux-media On Wed, 13 Jul 2011 18:05:45 -0300 Mauro Carvalho Chehab wrote: > Em 10-07-2011 16:51, Randy Dunlap escreveu: > > From: Randy Dunlap <rdunlap@xenotime.net> > > > > Add HEX_STRING(value) to stringify.h so that drivers can > > convert kconfig hex values (without leading "0x") to useful > > hex constants. > > > > Several drivers/media/radio/ drivers need this. I haven't > > checked if any other drivers need to do this. > > > > Alternatively, kconfig could produce hex config symbols with > > leading "0x". > > Hi Randy, > > After applying patch 1/9 and 2/9 over 3.0-rc7+media patches, I'm > now getting this error: > > drivers/media/radio/radio-aimslab.c:52:1: error: invalid suffix "x20f" on integer constant Hi Mauro, I built all of these drivers with my patches applied, but I'll see if I can find where this error is coming from. Thanks for checking & letting me know. > $ grep 20f .config > CONFIG_RADIO_RTRACK_PORT=20f > > $ gcc --version > gcc (GCC) 4.4.5 20110214 (Red Hat 4.4.5-6) > > Before this patch, this were working (or, at least, weren't producing > any error). > > Perhaps the breakage on your compilation happened due to another > patch at the tree? If so, the better would be to apply this patch > series together with the ones that caused the breakage, to avoid > bisect troubles. > > > > > Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> > > --- > > include/linux/stringify.h | 7 +++++++ > > 1 file changed, 7 insertions(+) > > > > NOTE: The other 8 patches are on lkml and linux-media mailing lists. > > > > --- linux-next-20110707.orig/include/linux/stringify.h > > +++ linux-next-20110707/include/linux/stringify.h > > @@ -9,4 +9,11 @@ > > #define __stringify_1(x...) #x > > #define __stringify(x...) __stringify_1(x) > > > > +/* > > + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, > > + * but kconfig does not put a leading "0x" on them. > > + */ > > +#define HEXSTRINGVALUE(h, value) h##value > > +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) > > + > > #endif /* !__LINUX_STRINGIFY_H */ > > -- --- ~Randy *** Remember to use Documentation/SubmitChecklist when testing your code *** ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-13 21:05 ` Mauro Carvalho Chehab 2011-07-13 21:11 ` Randy Dunlap @ 2011-07-13 22:04 ` Randy Dunlap 1 sibling, 0 replies; 18+ messages in thread From: Randy Dunlap @ 2011-07-13 22:04 UTC (permalink / raw) To: Mauro Carvalho Chehab; +Cc: lkml, linux-kbuild, linux-media On Wed, 13 Jul 2011 18:05:45 -0300 Mauro Carvalho Chehab wrote: > Em 10-07-2011 16:51, Randy Dunlap escreveu: > > From: Randy Dunlap <rdunlap@xenotime.net> > > > > Add HEX_STRING(value) to stringify.h so that drivers can > > convert kconfig hex values (without leading "0x") to useful > > hex constants. > > > > Several drivers/media/radio/ drivers need this. I haven't > > checked if any other drivers need to do this. > > > > Alternatively, kconfig could produce hex config symbols with > > leading "0x". > > Hi Randy, > > After applying patch 1/9 and 2/9 over 3.0-rc7+media patches, I'm > now getting this error: > > drivers/media/radio/radio-aimslab.c:52:1: error: invalid suffix "x20f" on integer constant > > $ grep 20f .config > CONFIG_RADIO_RTRACK_PORT=20f > > $ gcc --version > gcc (GCC) 4.4.5 20110214 (Red Hat 4.4.5-6) > > Before this patch, this were working (or, at least, weren't producing > any error). > > Perhaps the breakage on your compilation happened due to another > patch at the tree? If so, the better would be to apply this patch Do you suspect that? I built this patch series against the latest linux-next (20110707), so it should contain media patches as of that date. > series together with the ones that caused the breakage, to avoid > bisect troubles. Sure, if we know what patch it is (if there indeed is one). Can you do: $ make drivers/media/radio/radio-aimslab.i and tell me what this line contains for you? Mine says: static int io = 0x20f; > > > > Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> > > --- > > include/linux/stringify.h | 7 +++++++ > > 1 file changed, 7 insertions(+) > > > > NOTE: The other 8 patches are on lkml and linux-media mailing lists. > > > > --- linux-next-20110707.orig/include/linux/stringify.h > > +++ linux-next-20110707/include/linux/stringify.h > > @@ -9,4 +9,11 @@ > > #define __stringify_1(x...) #x > > #define __stringify(x...) __stringify_1(x) > > > > +/* > > + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, > > + * but kconfig does not put a leading "0x" on them. > > + */ > > +#define HEXSTRINGVALUE(h, value) h##value > > +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) > > + > > #endif /* !__LINUX_STRINGIFY_H */ > > -- --- ~Randy *** Remember to use Documentation/SubmitChecklist when testing your code *** ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-10 19:51 [PATCH 1/9] stringify: add HEX_STRING() Randy Dunlap 2011-07-13 21:05 ` Mauro Carvalho Chehab @ 2011-07-13 21:49 ` Arnaud Lacombe 2011-07-13 22:00 ` Randy Dunlap 1 sibling, 1 reply; 18+ messages in thread From: Arnaud Lacombe @ 2011-07-13 21:49 UTC (permalink / raw) To: Randy Dunlap; +Cc: lkml, linux-kbuild, linux-media, mchehab Hi, On Sun, Jul 10, 2011 at 3:51 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > From: Randy Dunlap <rdunlap@xenotime.net> > > Add HEX_STRING(value) to stringify.h so that drivers can > convert kconfig hex values (without leading "0x") to useful > hex constants. > > Several drivers/media/radio/ drivers need this. I haven't > checked if any other drivers need to do this. > > Alternatively, kconfig could produce hex config symbols with > leading "0x". > Actually, I used to have a patch to make hex value have a mandatory "0x" prefix, in the Kconfig. I even fixed all the issue in the tree, it never make it to the tree (not sure why). Here's the relevant thread: https://patchwork.kernel.org/patch/380591/ https://patchwork.kernel.org/patch/380621/ https://patchwork.kernel.org/patch/380601/ - Arnaud > Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> > --- > include/linux/stringify.h | 7 +++++++ > 1 file changed, 7 insertions(+) > > NOTE: The other 8 patches are on lkml and linux-media mailing lists. > > --- linux-next-20110707.orig/include/linux/stringify.h > +++ linux-next-20110707/include/linux/stringify.h > @@ -9,4 +9,11 @@ > #define __stringify_1(x...) #x > #define __stringify(x...) __stringify_1(x) > > +/* > + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, > + * but kconfig does not put a leading "0x" on them. > + */ > +#define HEXSTRINGVALUE(h, value) h##value > +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) > + that seems hackish... > #endif /* !__LINUX_STRINGIFY_H */ > -- > To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-13 21:49 ` Arnaud Lacombe @ 2011-07-13 22:00 ` Randy Dunlap 2011-07-13 22:06 ` Arnaud Lacombe 0 siblings, 1 reply; 18+ messages in thread From: Randy Dunlap @ 2011-07-13 22:00 UTC (permalink / raw) To: Arnaud Lacombe; +Cc: lkml, linux-kbuild, linux-media, mchehab On Wed, 13 Jul 2011 17:49:48 -0400 Arnaud Lacombe wrote: > Hi, > > On Sun, Jul 10, 2011 at 3:51 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > > From: Randy Dunlap <rdunlap@xenotime.net> > > > > Add HEX_STRING(value) to stringify.h so that drivers can > > convert kconfig hex values (without leading "0x") to useful > > hex constants. > > > > Several drivers/media/radio/ drivers need this. I haven't > > checked if any other drivers need to do this. > > > > Alternatively, kconfig could produce hex config symbols with > > leading "0x". > > > Actually, I used to have a patch to make hex value have a mandatory > "0x" prefix, in the Kconfig. I even fixed all the issue in the tree, > it never make it to the tree (not sure why). Here's the relevant > thread: > > https://patchwork.kernel.org/patch/380591/ > https://patchwork.kernel.org/patch/380621/ > https://patchwork.kernel.org/patch/380601/ > I prefer that this be fixed in kconfig, so long as it won't cause any other issues. That's why I mentioned it. > > > Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> > > --- > > include/linux/stringify.h | 7 +++++++ > > 1 file changed, 7 insertions(+) > > > > NOTE: The other 8 patches are on lkml and linux-media mailing lists. > > > > --- linux-next-20110707.orig/include/linux/stringify.h > > +++ linux-next-20110707/include/linux/stringify.h > > @@ -9,4 +9,11 @@ > > #define __stringify_1(x...) #x > > #define __stringify(x...) __stringify_1(x) > > > > +/* > > + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, > > + * but kconfig does not put a leading "0x" on them. > > + */ > > +#define HEXSTRINGVALUE(h, value) h##value > > +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) > > + > that seems hackish... It's a common idiom for concatenating strings in the kernel. How would you do it without (instead of) a kconfig fix/patch? > > #endif /* !__LINUX_STRINGIFY_H */ > > -- --- ~Randy *** Remember to use Documentation/SubmitChecklist when testing your code *** ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-13 22:00 ` Randy Dunlap @ 2011-07-13 22:06 ` Arnaud Lacombe 2011-07-13 22:08 ` Randy Dunlap 0 siblings, 1 reply; 18+ messages in thread From: Arnaud Lacombe @ 2011-07-13 22:06 UTC (permalink / raw) To: Randy Dunlap; +Cc: lkml, linux-kbuild, linux-media, mchehab Hi, On Wed, Jul 13, 2011 at 6:00 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > On Wed, 13 Jul 2011 17:49:48 -0400 Arnaud Lacombe wrote: > >> Hi, >> >> On Sun, Jul 10, 2011 at 3:51 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: >> > From: Randy Dunlap <rdunlap@xenotime.net> >> > >> > Add HEX_STRING(value) to stringify.h so that drivers can >> > convert kconfig hex values (without leading "0x") to useful >> > hex constants. >> > >> > Several drivers/media/radio/ drivers need this. I haven't >> > checked if any other drivers need to do this. >> > >> > Alternatively, kconfig could produce hex config symbols with >> > leading "0x". >> > >> Actually, I used to have a patch to make hex value have a mandatory >> "0x" prefix, in the Kconfig. I even fixed all the issue in the tree, >> it never make it to the tree (not sure why). Here's the relevant >> thread: >> >> https://patchwork.kernel.org/patch/380591/ >> https://patchwork.kernel.org/patch/380621/ >> https://patchwork.kernel.org/patch/380601/ >> > > I prefer that this be fixed in kconfig, so long as it won't cause > any other issues. That's why I mentioned it. > >> >> > Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> >> > --- >> > include/linux/stringify.h | 7 +++++++ >> > 1 file changed, 7 insertions(+) >> > >> > NOTE: The other 8 patches are on lkml and linux-media mailing lists. >> > >> > --- linux-next-20110707.orig/include/linux/stringify.h >> > +++ linux-next-20110707/include/linux/stringify.h >> > @@ -9,4 +9,11 @@ >> > #define __stringify_1(x...) #x >> > #define __stringify(x...) __stringify_1(x) >> > >> > +/* >> > + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, >> > + * but kconfig does not put a leading "0x" on them. >> > + */ >> > +#define HEXSTRINGVALUE(h, value) h##value >> > +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) >> > + >> that seems hackish... > > It's a common idiom for concatenating strings in the kernel. > I meant hackish not because *how* it is done, but because *why* it has to be done, that is, because the Kconfig miss the prefix, which is really no big deal. > How would you do it without (instead of) a kconfig fix/patch? > have the Kconfig use the "0x" prefix since the beginning. - Arnaud >> > #endif /* !__LINUX_STRINGIFY_H */ >> > -- > > > --- > ~Randy > *** Remember to use Documentation/SubmitChecklist when testing your code *** > ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-13 22:06 ` Arnaud Lacombe @ 2011-07-13 22:08 ` Randy Dunlap 2011-07-13 22:13 ` Arnaud Lacombe 0 siblings, 1 reply; 18+ messages in thread From: Randy Dunlap @ 2011-07-13 22:08 UTC (permalink / raw) To: Arnaud Lacombe; +Cc: lkml, linux-kbuild, linux-media, mchehab On Wed, 13 Jul 2011 18:06:15 -0400 Arnaud Lacombe wrote: > Hi, > > On Wed, Jul 13, 2011 at 6:00 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > > On Wed, 13 Jul 2011 17:49:48 -0400 Arnaud Lacombe wrote: > > > >> Hi, > >> > >> On Sun, Jul 10, 2011 at 3:51 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > >> > From: Randy Dunlap <rdunlap@xenotime.net> > >> > > >> > Add HEX_STRING(value) to stringify.h so that drivers can > >> > convert kconfig hex values (without leading "0x") to useful > >> > hex constants. > >> > > >> > Several drivers/media/radio/ drivers need this. I haven't > >> > checked if any other drivers need to do this. > >> > > >> > Alternatively, kconfig could produce hex config symbols with > >> > leading "0x". > >> > > >> Actually, I used to have a patch to make hex value have a mandatory > >> "0x" prefix, in the Kconfig. I even fixed all the issue in the tree, > >> it never make it to the tree (not sure why). Here's the relevant > >> thread: > >> > >> https://patchwork.kernel.org/patch/380591/ > >> https://patchwork.kernel.org/patch/380621/ > >> https://patchwork.kernel.org/patch/380601/ > >> > > > > I prefer that this be fixed in kconfig, so long as it won't cause > > any other issues. That's why I mentioned it. > > > >> > >> > Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> > >> > --- > >> > include/linux/stringify.h | 7 +++++++ > >> > 1 file changed, 7 insertions(+) > >> > > >> > NOTE: The other 8 patches are on lkml and linux-media mailing lists. > >> > > >> > --- linux-next-20110707.orig/include/linux/stringify.h > >> > +++ linux-next-20110707/include/linux/stringify.h > >> > @@ -9,4 +9,11 @@ > >> > #define __stringify_1(x...) #x > >> > #define __stringify(x...) __stringify_1(x) > >> > > >> > +/* > >> > + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, > >> > + * but kconfig does not put a leading "0x" on them. > >> > + */ > >> > +#define HEXSTRINGVALUE(h, value) h##value > >> > +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) > >> > + > >> that seems hackish... > > > > It's a common idiom for concatenating strings in the kernel. > > > I meant hackish not because *how* it is done, but because *why* it has > to be done, that is, because the Kconfig miss the prefix, which is > really no big deal. > > > How would you do it without (instead of) a kconfig fix/patch? > > > have the Kconfig use the "0x" prefix since the beginning. Sure, go for it. I'll ack it. ;) [or Review it :] and test it. thanks, --- ~Randy *** Remember to use Documentation/SubmitChecklist when testing your code *** ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-13 22:08 ` Randy Dunlap @ 2011-07-13 22:13 ` Arnaud Lacombe 2011-07-13 22:17 ` Randy Dunlap 0 siblings, 1 reply; 18+ messages in thread From: Arnaud Lacombe @ 2011-07-13 22:13 UTC (permalink / raw) To: Randy Dunlap; +Cc: lkml, linux-kbuild, linux-media, mchehab Hi, On Wed, Jul 13, 2011 at 6:08 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > On Wed, 13 Jul 2011 18:06:15 -0400 Arnaud Lacombe wrote: > >> Hi, >> >> On Wed, Jul 13, 2011 at 6:00 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: >> > On Wed, 13 Jul 2011 17:49:48 -0400 Arnaud Lacombe wrote: >> > >> >> Hi, >> >> >> >> On Sun, Jul 10, 2011 at 3:51 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: >> >> > From: Randy Dunlap <rdunlap@xenotime.net> >> >> > >> >> > Add HEX_STRING(value) to stringify.h so that drivers can >> >> > convert kconfig hex values (without leading "0x") to useful >> >> > hex constants. >> >> > >> >> > Several drivers/media/radio/ drivers need this. I haven't >> >> > checked if any other drivers need to do this. >> >> > >> >> > Alternatively, kconfig could produce hex config symbols with >> >> > leading "0x". >> >> > >> >> Actually, I used to have a patch to make hex value have a mandatory >> >> "0x" prefix, in the Kconfig. I even fixed all the issue in the tree, >> >> it never make it to the tree (not sure why). Here's the relevant >> >> thread: >> >> >> >> https://patchwork.kernel.org/patch/380591/ >> >> https://patchwork.kernel.org/patch/380621/ >> >> https://patchwork.kernel.org/patch/380601/ >> >> >> > >> > I prefer that this be fixed in kconfig, so long as it won't cause >> > any other issues. That's why I mentioned it. >> > >> >> >> >> > Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> >> >> > --- >> >> > include/linux/stringify.h | 7 +++++++ >> >> > 1 file changed, 7 insertions(+) >> >> > >> >> > NOTE: The other 8 patches are on lkml and linux-media mailing lists. >> >> > >> >> > --- linux-next-20110707.orig/include/linux/stringify.h >> >> > +++ linux-next-20110707/include/linux/stringify.h >> >> > @@ -9,4 +9,11 @@ >> >> > #define __stringify_1(x...) #x >> >> > #define __stringify(x...) __stringify_1(x) >> >> > >> >> > +/* >> >> > + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, >> >> > + * but kconfig does not put a leading "0x" on them. >> >> > + */ >> >> > +#define HEXSTRINGVALUE(h, value) h##value >> >> > +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) >> >> > + >> >> that seems hackish... >> > >> > It's a common idiom for concatenating strings in the kernel. >> > >> I meant hackish not because *how* it is done, but because *why* it has >> to be done, that is, because the Kconfig miss the prefix, which is >> really no big deal. >> >> > How would you do it without (instead of) a kconfig fix/patch? >> > >> have the Kconfig use the "0x" prefix since the beginning. > > Sure, go for it. I'll ack it. ;) [or Review it :] > and test it. > it is already among the hunks in https://patchwork.kernel.org/patch/380601/ - Arnaud ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-13 22:13 ` Arnaud Lacombe @ 2011-07-13 22:17 ` Randy Dunlap 2011-07-14 4:03 ` Arnaud Lacombe 2011-07-14 17:26 ` [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols Arnaud Lacombe 0 siblings, 2 replies; 18+ messages in thread From: Randy Dunlap @ 2011-07-13 22:17 UTC (permalink / raw) To: Arnaud Lacombe; +Cc: lkml, linux-kbuild, linux-media, mchehab On Wed, 13 Jul 2011 18:13:31 -0400 Arnaud Lacombe wrote: > Hi, > > On Wed, Jul 13, 2011 at 6:08 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > > On Wed, 13 Jul 2011 18:06:15 -0400 Arnaud Lacombe wrote: > > > >> Hi, > >> > >> On Wed, Jul 13, 2011 at 6:00 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > >> > On Wed, 13 Jul 2011 17:49:48 -0400 Arnaud Lacombe wrote: > >> > > >> >> Hi, > >> >> > >> >> On Sun, Jul 10, 2011 at 3:51 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > >> >> > From: Randy Dunlap <rdunlap@xenotime.net> > >> >> > > >> >> > Add HEX_STRING(value) to stringify.h so that drivers can > >> >> > convert kconfig hex values (without leading "0x") to useful > >> >> > hex constants. > >> >> > > >> >> > Several drivers/media/radio/ drivers need this. I haven't > >> >> > checked if any other drivers need to do this. > >> >> > > >> >> > Alternatively, kconfig could produce hex config symbols with > >> >> > leading "0x". > >> >> > > >> >> Actually, I used to have a patch to make hex value have a mandatory > >> >> "0x" prefix, in the Kconfig. I even fixed all the issue in the tree, > >> >> it never make it to the tree (not sure why). Here's the relevant > >> >> thread: > >> >> > >> >> https://patchwork.kernel.org/patch/380591/ > >> >> https://patchwork.kernel.org/patch/380621/ > >> >> https://patchwork.kernel.org/patch/380601/ > >> >> > >> > > >> > I prefer that this be fixed in kconfig, so long as it won't cause > >> > any other issues. That's why I mentioned it. > >> > > >> >> > >> >> > Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> > >> >> > --- > >> >> > include/linux/stringify.h | 7 +++++++ > >> >> > 1 file changed, 7 insertions(+) > >> >> > > >> >> > NOTE: The other 8 patches are on lkml and linux-media mailing lists. > >> >> > > >> >> > --- linux-next-20110707.orig/include/linux/stringify.h > >> >> > +++ linux-next-20110707/include/linux/stringify.h > >> >> > @@ -9,4 +9,11 @@ > >> >> > #define __stringify_1(x...) #x > >> >> > #define __stringify(x...) __stringify_1(x) > >> >> > > >> >> > +/* > >> >> > + * HEX_STRING(value) is useful for CONFIG_ values that are in hex, > >> >> > + * but kconfig does not put a leading "0x" on them. > >> >> > + */ > >> >> > +#define HEXSTRINGVALUE(h, value) h##value > >> >> > +#define HEX_STRING(value) HEXSTRINGVALUE(0x, value) > >> >> > + > >> >> that seems hackish... > >> > > >> > It's a common idiom for concatenating strings in the kernel. > >> > > >> I meant hackish not because *how* it is done, but because *why* it has > >> to be done, that is, because the Kconfig miss the prefix, which is > >> really no big deal. > >> > >> > How would you do it without (instead of) a kconfig fix/patch? > >> > > >> have the Kconfig use the "0x" prefix since the beginning. > > > > Sure, go for it. I'll ack it. ;) [or Review it :] > > and test it. > > > it is already among the hunks in https://patchwork.kernel.org/patch/380601/ I realize that, but it looks like you may need to resubmit it. I'll dig it out and test it, maybe even reply to your old patch(es). --- ~Randy *** Remember to use Documentation/SubmitChecklist when testing your code *** ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/9] stringify: add HEX_STRING() 2011-07-13 22:17 ` Randy Dunlap @ 2011-07-14 4:03 ` Arnaud Lacombe 2011-07-14 17:26 ` [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols Arnaud Lacombe 1 sibling, 0 replies; 18+ messages in thread From: Arnaud Lacombe @ 2011-07-14 4:03 UTC (permalink / raw) To: Randy Dunlap; +Cc: lkml, linux-kbuild, linux-media, mchehab Hi, On Wed, Jul 13, 2011 at 6:17 PM, Randy Dunlap <rdunlap@xenotime.net> wrote: > [...] >> > Sure, go for it. I'll ack it. ;) [or Review it :] >> > and test it. >> > >> it is already among the hunks in https://patchwork.kernel.org/patch/380601/ > > I realize that, but it looks like you may need to resubmit it. > I have an updated set of patches against -next, I still need to break them down by tree. As a lots of things I did today went completely south, I guess it would be better if I do this task early tomorrow :-) - Arnaud ^ permalink raw reply [flat|nested] 18+ messages in thread
* [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols 2011-07-13 22:17 ` Randy Dunlap 2011-07-14 4:03 ` Arnaud Lacombe @ 2011-07-14 17:26 ` Arnaud Lacombe 2011-07-14 18:16 ` Mauro Carvalho Chehab 2011-07-24 21:38 ` Arnaud Lacombe 1 sibling, 2 replies; 18+ messages in thread From: Arnaud Lacombe @ 2011-07-14 17:26 UTC (permalink / raw) To: linux-kbuild; +Cc: Arnaud Lacombe, Mauro Carvalho Chehab, Randy Dunlap Cc: Mauro Carvalho Chehab <mchehab@infradead.org> Cc: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Arnaud Lacombe <lacombar@gmail.com> --- drivers/media/radio/Kconfig | 16 ++++++++-------- 1 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig index e4c97fd..9cab04d 100644 --- a/drivers/media/radio/Kconfig +++ b/drivers/media/radio/Kconfig @@ -58,7 +58,7 @@ config RADIO_RTRACK config RADIO_RTRACK_PORT hex "RadioTrack i/o port (0x20f or 0x30f)" depends on RADIO_RTRACK=y - default "20f" + default "0x20f" help Enter either 0x30f or 0x20f here. The card default is 0x30f, if you haven't changed the jumper setting on the card. @@ -81,7 +81,7 @@ config RADIO_RTRACK2 config RADIO_RTRACK2_PORT hex "RadioTrack II i/o port (0x20c or 0x30c)" depends on RADIO_RTRACK2=y - default "30c" + default "0x30c" help Enter either 0x30c or 0x20c here. The card default is 0x30c, if you haven't changed the jumper setting on the card. @@ -104,7 +104,7 @@ config RADIO_AZTECH config RADIO_AZTECH_PORT hex "Aztech/Packard Bell I/O port (0x350 or 0x358)" depends on RADIO_AZTECH=y - default "350" + default "0x350" help Enter either 0x350 or 0x358 here. The card default is 0x350, if you haven't changed the setting of jumper JP3 on the card. Removing the @@ -133,7 +133,7 @@ config RADIO_GEMTEK config RADIO_GEMTEK_PORT hex "Fixed I/O port (0x20c, 0x30c, 0x24c, 0x34c, 0c24c or 0x28c)" depends on RADIO_GEMTEK=y - default "34c" + default "0x34c" help Enter either 0x20c, 0x30c, 0x24c or 0x34c here. The card default is 0x34c, if you haven't changed the jumper setting on the card. On @@ -237,7 +237,7 @@ config RADIO_TERRATEC config RADIO_TERRATEC_PORT hex "Terratec i/o port (normally 0x590)" depends on RADIO_TERRATEC=y - default "590" + default "0x590" help Fill in the I/O port of your TerraTec FM radio card. If unsure, go with the default. @@ -255,7 +255,7 @@ config RADIO_TRUST config RADIO_TRUST_PORT hex "Trust i/o port (usually 0x350 or 0x358)" depends on RADIO_TRUST=y - default "350" + default "0x350" help Enter the I/O port of your Trust FM radio card. If unsure, try the values "0x350" or "0x358". @@ -278,7 +278,7 @@ config RADIO_TYPHOON config RADIO_TYPHOON_PORT hex "Typhoon I/O port (0x316 or 0x336)" depends on RADIO_TYPHOON=y - default "316" + default "0x316" help Enter the I/O port of your Typhoon or EcoRadio radio card. @@ -312,7 +312,7 @@ config RADIO_ZOLTRIX config RADIO_ZOLTRIX_PORT hex "ZOLTRIX I/O port (0x20c or 0x30c)" depends on RADIO_ZOLTRIX=y - default "20c" + default "0x20c" help Enter the I/O port of your Zoltrix radio card. -- 1.7.3.4.574.g608b.dirty ^ permalink raw reply related [flat|nested] 18+ messages in thread
* Re: [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols 2011-07-14 17:26 ` [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols Arnaud Lacombe @ 2011-07-14 18:16 ` Mauro Carvalho Chehab 2011-07-14 18:47 ` Arnaud Lacombe 2011-07-14 23:32 ` Arnaud Lacombe 2011-07-24 21:38 ` Arnaud Lacombe 1 sibling, 2 replies; 18+ messages in thread From: Mauro Carvalho Chehab @ 2011-07-14 18:16 UTC (permalink / raw) To: Arnaud Lacombe; +Cc: linux-kbuild, Randy Dunlap Em 14-07-2011 14:26, Arnaud Lacombe escreveu: > Cc: Mauro Carvalho Chehab <mchehab@infradead.org> > Cc: Randy Dunlap <rdunlap@xenotime.net> > Signed-off-by: Arnaud Lacombe <lacombar@gmail.com> Arnaud, The patch is ok for me. You can add my acked-by, if you want. However, with 3.0-rc7, this patch and/or Kconfig fixes don't seem to be needed. Basically, include/generated/autoconf.h has "0x" on it: $ grep CONFIG_RADIO_RTRACK_PORT */*/* include/config/auto.conf:CONFIG_RADIO_RTRACK_PORT=20f include/generated/autoconf.h:#define CONFIG_RADIO_RTRACK_PORT 0x20f Maybe some patch applied at -next from another tree broke that behavior. IMHO, keeping those values without "0x" at Kconfig seems more intuitive for the end-user, as otherwise a value like "200" would be confusing if this means 200d or 200h. Anyway, those drivers are very old, and very few people likely still use those old hardware. So, I'm fine if you either want to preserve the current way or to change it. Cheers, Mauro. > --- > drivers/media/radio/Kconfig | 16 ++++++++-------- > 1 files changed, 8 insertions(+), 8 deletions(-) > > diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig > index e4c97fd..9cab04d 100644 > --- a/drivers/media/radio/Kconfig > +++ b/drivers/media/radio/Kconfig > @@ -58,7 +58,7 @@ config RADIO_RTRACK > config RADIO_RTRACK_PORT > hex "RadioTrack i/o port (0x20f or 0x30f)" > depends on RADIO_RTRACK=y > - default "20f" > + default "0x20f" > help > Enter either 0x30f or 0x20f here. The card default is 0x30f, if you > haven't changed the jumper setting on the card. > @@ -81,7 +81,7 @@ config RADIO_RTRACK2 > config RADIO_RTRACK2_PORT > hex "RadioTrack II i/o port (0x20c or 0x30c)" > depends on RADIO_RTRACK2=y > - default "30c" > + default "0x30c" > help > Enter either 0x30c or 0x20c here. The card default is 0x30c, if you > haven't changed the jumper setting on the card. > @@ -104,7 +104,7 @@ config RADIO_AZTECH > config RADIO_AZTECH_PORT > hex "Aztech/Packard Bell I/O port (0x350 or 0x358)" > depends on RADIO_AZTECH=y > - default "350" > + default "0x350" > help > Enter either 0x350 or 0x358 here. The card default is 0x350, if you > haven't changed the setting of jumper JP3 on the card. Removing the > @@ -133,7 +133,7 @@ config RADIO_GEMTEK > config RADIO_GEMTEK_PORT > hex "Fixed I/O port (0x20c, 0x30c, 0x24c, 0x34c, 0c24c or 0x28c)" > depends on RADIO_GEMTEK=y > - default "34c" > + default "0x34c" > help > Enter either 0x20c, 0x30c, 0x24c or 0x34c here. The card default is > 0x34c, if you haven't changed the jumper setting on the card. On > @@ -237,7 +237,7 @@ config RADIO_TERRATEC > config RADIO_TERRATEC_PORT > hex "Terratec i/o port (normally 0x590)" > depends on RADIO_TERRATEC=y > - default "590" > + default "0x590" > help > Fill in the I/O port of your TerraTec FM radio card. If unsure, go > with the default. > @@ -255,7 +255,7 @@ config RADIO_TRUST > config RADIO_TRUST_PORT > hex "Trust i/o port (usually 0x350 or 0x358)" > depends on RADIO_TRUST=y > - default "350" > + default "0x350" > help > Enter the I/O port of your Trust FM radio card. If unsure, try the > values "0x350" or "0x358". > @@ -278,7 +278,7 @@ config RADIO_TYPHOON > config RADIO_TYPHOON_PORT > hex "Typhoon I/O port (0x316 or 0x336)" > depends on RADIO_TYPHOON=y > - default "316" > + default "0x316" > help > Enter the I/O port of your Typhoon or EcoRadio radio card. > > @@ -312,7 +312,7 @@ config RADIO_ZOLTRIX > config RADIO_ZOLTRIX_PORT > hex "ZOLTRIX I/O port (0x20c or 0x30c)" > depends on RADIO_ZOLTRIX=y > - default "20c" > + default "0x20c" > help > Enter the I/O port of your Zoltrix radio card. > ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols 2011-07-14 18:16 ` Mauro Carvalho Chehab @ 2011-07-14 18:47 ` Arnaud Lacombe 2011-07-14 23:32 ` Arnaud Lacombe 1 sibling, 0 replies; 18+ messages in thread From: Arnaud Lacombe @ 2011-07-14 18:47 UTC (permalink / raw) To: Mauro Carvalho Chehab; +Cc: linux-kbuild, Randy Dunlap Hi, On Thu, Jul 14, 2011 at 2:16 PM, Mauro Carvalho Chehab <mchehab@infradead.org> wrote: > Em 14-07-2011 14:26, Arnaud Lacombe escreveu: >> Cc: Mauro Carvalho Chehab <mchehab@infradead.org> >> Cc: Randy Dunlap <rdunlap@xenotime.net> >> Signed-off-by: Arnaud Lacombe <lacombar@gmail.com> > > Arnaud, > > The patch is ok for me. You can add my acked-by, if you want. > > However, with 3.0-rc7, this patch and/or Kconfig fixes don't seem to > be needed. Basically, include/generated/autoconf.h has "0x" on it: > > $ grep CONFIG_RADIO_RTRACK_PORT */*/* > include/config/auto.conf:CONFIG_RADIO_RTRACK_PORT=20f > include/generated/autoconf.h:#define CONFIG_RADIO_RTRACK_PORT 0x20f > > Maybe some patch applied at -next from another tree broke that behavior. > he ... I (involuntarily) broke that behavior when reworking the way we generate autoconf.h :-) my bad. - Arnaud > IMHO, keeping those values without "0x" at Kconfig seems more intuitive > for the end-user, as otherwise a value like "200" would be confusing > if this means 200d or 200h. > do you mean more intuitive *with* "0x", not *without* ? This is what I'm thinking too, and why I'd make the "0x" mandatory on HEX symbols. > Anyway, those drivers are very old, and very few people likely still > use those old hardware. So, I'm fine if you either want to preserve > the current way or to change it. > > Cheers, > Mauro. > >> --- >> drivers/media/radio/Kconfig | 16 ++++++++-------- >> 1 files changed, 8 insertions(+), 8 deletions(-) >> >> diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig >> index e4c97fd..9cab04d 100644 >> --- a/drivers/media/radio/Kconfig >> +++ b/drivers/media/radio/Kconfig >> @@ -58,7 +58,7 @@ config RADIO_RTRACK >> config RADIO_RTRACK_PORT >> hex "RadioTrack i/o port (0x20f or 0x30f)" >> depends on RADIO_RTRACK=y >> - default "20f" >> + default "0x20f" >> help >> Enter either 0x30f or 0x20f here. The card default is 0x30f, if you >> haven't changed the jumper setting on the card. >> @@ -81,7 +81,7 @@ config RADIO_RTRACK2 >> config RADIO_RTRACK2_PORT >> hex "RadioTrack II i/o port (0x20c or 0x30c)" >> depends on RADIO_RTRACK2=y >> - default "30c" >> + default "0x30c" >> help >> Enter either 0x30c or 0x20c here. The card default is 0x30c, if you >> haven't changed the jumper setting on the card. >> @@ -104,7 +104,7 @@ config RADIO_AZTECH >> config RADIO_AZTECH_PORT >> hex "Aztech/Packard Bell I/O port (0x350 or 0x358)" >> depends on RADIO_AZTECH=y >> - default "350" >> + default "0x350" >> help >> Enter either 0x350 or 0x358 here. The card default is 0x350, if you >> haven't changed the setting of jumper JP3 on the card. Removing the >> @@ -133,7 +133,7 @@ config RADIO_GEMTEK >> config RADIO_GEMTEK_PORT >> hex "Fixed I/O port (0x20c, 0x30c, 0x24c, 0x34c, 0c24c or 0x28c)" >> depends on RADIO_GEMTEK=y >> - default "34c" >> + default "0x34c" >> help >> Enter either 0x20c, 0x30c, 0x24c or 0x34c here. The card default is >> 0x34c, if you haven't changed the jumper setting on the card. On >> @@ -237,7 +237,7 @@ config RADIO_TERRATEC >> config RADIO_TERRATEC_PORT >> hex "Terratec i/o port (normally 0x590)" >> depends on RADIO_TERRATEC=y >> - default "590" >> + default "0x590" >> help >> Fill in the I/O port of your TerraTec FM radio card. If unsure, go >> with the default. >> @@ -255,7 +255,7 @@ config RADIO_TRUST >> config RADIO_TRUST_PORT >> hex "Trust i/o port (usually 0x350 or 0x358)" >> depends on RADIO_TRUST=y >> - default "350" >> + default "0x350" >> help >> Enter the I/O port of your Trust FM radio card. If unsure, try the >> values "0x350" or "0x358". >> @@ -278,7 +278,7 @@ config RADIO_TYPHOON >> config RADIO_TYPHOON_PORT >> hex "Typhoon I/O port (0x316 or 0x336)" >> depends on RADIO_TYPHOON=y >> - default "316" >> + default "0x316" >> help >> Enter the I/O port of your Typhoon or EcoRadio radio card. >> >> @@ -312,7 +312,7 @@ config RADIO_ZOLTRIX >> config RADIO_ZOLTRIX_PORT >> hex "ZOLTRIX I/O port (0x20c or 0x30c)" >> depends on RADIO_ZOLTRIX=y >> - default "20c" >> + default "0x20c" >> help >> Enter the I/O port of your Zoltrix radio card. >> > > ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols 2011-07-14 18:16 ` Mauro Carvalho Chehab 2011-07-14 18:47 ` Arnaud Lacombe @ 2011-07-14 23:32 ` Arnaud Lacombe 2011-07-15 0:01 ` Mauro Carvalho Chehab 1 sibling, 1 reply; 18+ messages in thread From: Arnaud Lacombe @ 2011-07-14 23:32 UTC (permalink / raw) To: Mauro Carvalho Chehab; +Cc: linux-kbuild, Randy Dunlap Hi, On Thu, Jul 14, 2011 at 2:16 PM, Mauro Carvalho Chehab <mchehab@infradead.org> wrote: > Em 14-07-2011 14:26, Arnaud Lacombe escreveu: >> Cc: Mauro Carvalho Chehab <mchehab@infradead.org> >> Cc: Randy Dunlap <rdunlap@xenotime.net> >> Signed-off-by: Arnaud Lacombe <lacombar@gmail.com> > > Arnaud, > > The patch is ok for me. You can add my acked-by, if you want. > don't you want to take in though the media/video tree for -next ? - Arnaud > However, with 3.0-rc7, this patch and/or Kconfig fixes don't seem to > be needed. Basically, include/generated/autoconf.h has "0x" on it: > > $ grep CONFIG_RADIO_RTRACK_PORT */*/* > include/config/auto.conf:CONFIG_RADIO_RTRACK_PORT=20f > include/generated/autoconf.h:#define CONFIG_RADIO_RTRACK_PORT 0x20f > > Maybe some patch applied at -next from another tree broke that behavior. > > IMHO, keeping those values without "0x" at Kconfig seems more intuitive > for the end-user, as otherwise a value like "200" would be confusing > if this means 200d or 200h. > > Anyway, those drivers are very old, and very few people likely still > use those old hardware. So, I'm fine if you either want to preserve > the current way or to change it. > > Cheers, > Mauro. > >> --- >> drivers/media/radio/Kconfig | 16 ++++++++-------- >> 1 files changed, 8 insertions(+), 8 deletions(-) >> >> diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig >> index e4c97fd..9cab04d 100644 >> --- a/drivers/media/radio/Kconfig >> +++ b/drivers/media/radio/Kconfig >> @@ -58,7 +58,7 @@ config RADIO_RTRACK >> config RADIO_RTRACK_PORT >> hex "RadioTrack i/o port (0x20f or 0x30f)" >> depends on RADIO_RTRACK=y >> - default "20f" >> + default "0x20f" >> help >> Enter either 0x30f or 0x20f here. The card default is 0x30f, if you >> haven't changed the jumper setting on the card. >> @@ -81,7 +81,7 @@ config RADIO_RTRACK2 >> config RADIO_RTRACK2_PORT >> hex "RadioTrack II i/o port (0x20c or 0x30c)" >> depends on RADIO_RTRACK2=y >> - default "30c" >> + default "0x30c" >> help >> Enter either 0x30c or 0x20c here. The card default is 0x30c, if you >> haven't changed the jumper setting on the card. >> @@ -104,7 +104,7 @@ config RADIO_AZTECH >> config RADIO_AZTECH_PORT >> hex "Aztech/Packard Bell I/O port (0x350 or 0x358)" >> depends on RADIO_AZTECH=y >> - default "350" >> + default "0x350" >> help >> Enter either 0x350 or 0x358 here. The card default is 0x350, if you >> haven't changed the setting of jumper JP3 on the card. Removing the >> @@ -133,7 +133,7 @@ config RADIO_GEMTEK >> config RADIO_GEMTEK_PORT >> hex "Fixed I/O port (0x20c, 0x30c, 0x24c, 0x34c, 0c24c or 0x28c)" >> depends on RADIO_GEMTEK=y >> - default "34c" >> + default "0x34c" >> help >> Enter either 0x20c, 0x30c, 0x24c or 0x34c here. The card default is >> 0x34c, if you haven't changed the jumper setting on the card. On >> @@ -237,7 +237,7 @@ config RADIO_TERRATEC >> config RADIO_TERRATEC_PORT >> hex "Terratec i/o port (normally 0x590)" >> depends on RADIO_TERRATEC=y >> - default "590" >> + default "0x590" >> help >> Fill in the I/O port of your TerraTec FM radio card. If unsure, go >> with the default. >> @@ -255,7 +255,7 @@ config RADIO_TRUST >> config RADIO_TRUST_PORT >> hex "Trust i/o port (usually 0x350 or 0x358)" >> depends on RADIO_TRUST=y >> - default "350" >> + default "0x350" >> help >> Enter the I/O port of your Trust FM radio card. If unsure, try the >> values "0x350" or "0x358". >> @@ -278,7 +278,7 @@ config RADIO_TYPHOON >> config RADIO_TYPHOON_PORT >> hex "Typhoon I/O port (0x316 or 0x336)" >> depends on RADIO_TYPHOON=y >> - default "316" >> + default "0x316" >> help >> Enter the I/O port of your Typhoon or EcoRadio radio card. >> >> @@ -312,7 +312,7 @@ config RADIO_ZOLTRIX >> config RADIO_ZOLTRIX_PORT >> hex "ZOLTRIX I/O port (0x20c or 0x30c)" >> depends on RADIO_ZOLTRIX=y >> - default "20c" >> + default "0x20c" >> help >> Enter the I/O port of your Zoltrix radio card. >> > > ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols 2011-07-14 23:32 ` Arnaud Lacombe @ 2011-07-15 0:01 ` Mauro Carvalho Chehab 2011-07-15 1:39 ` Arnaud Lacombe 0 siblings, 1 reply; 18+ messages in thread From: Mauro Carvalho Chehab @ 2011-07-15 0:01 UTC (permalink / raw) To: Arnaud Lacombe; +Cc: linux-kbuild, Randy Dunlap Em 14-07-2011 20:32, Arnaud Lacombe escreveu: > Hi, > > On Thu, Jul 14, 2011 at 2:16 PM, Mauro Carvalho Chehab > <mchehab@infradead.org> wrote: >> Em 14-07-2011 14:26, Arnaud Lacombe escreveu: >>> Cc: Mauro Carvalho Chehab <mchehab@infradead.org> >>> Cc: Randy Dunlap <rdunlap@xenotime.net> >>> Signed-off-by: Arnaud Lacombe <lacombar@gmail.com> >> >> Arnaud, >> >> The patch is ok for me. You can add my acked-by, if you want. >> > don't you want to take in though the media/video tree for -next ? It seems better if you could put it on your tree, before the patch that broke the Kconfig. Otherwise, you'll need to wait for my merge upstream, before being sending yours, to avoid breaking git bisect. Anyway, I'm ok to add it into my tree if you prefer this way. Thanks! Mauro > > - Arnaud > >> However, with 3.0-rc7, this patch and/or Kconfig fixes don't seem to >> be needed. Basically, include/generated/autoconf.h has "0x" on it: >> >> $ grep CONFIG_RADIO_RTRACK_PORT */*/* >> include/config/auto.conf:CONFIG_RADIO_RTRACK_PORT=20f >> include/generated/autoconf.h:#define CONFIG_RADIO_RTRACK_PORT 0x20f >> >> Maybe some patch applied at -next from another tree broke that behavior. >> >> IMHO, keeping those values without "0x" at Kconfig seems more intuitive >> for the end-user, as otherwise a value like "200" would be confusing >> if this means 200d or 200h. >> >> Anyway, those drivers are very old, and very few people likely still >> use those old hardware. So, I'm fine if you either want to preserve >> the current way or to change it. >> >> Cheers, >> Mauro. >> >>> --- >>> drivers/media/radio/Kconfig | 16 ++++++++-------- >>> 1 files changed, 8 insertions(+), 8 deletions(-) >>> >>> diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig >>> index e4c97fd..9cab04d 100644 >>> --- a/drivers/media/radio/Kconfig >>> +++ b/drivers/media/radio/Kconfig >>> @@ -58,7 +58,7 @@ config RADIO_RTRACK >>> config RADIO_RTRACK_PORT >>> hex "RadioTrack i/o port (0x20f or 0x30f)" >>> depends on RADIO_RTRACK=y >>> - default "20f" >>> + default "0x20f" >>> help >>> Enter either 0x30f or 0x20f here. The card default is 0x30f, if you >>> haven't changed the jumper setting on the card. >>> @@ -81,7 +81,7 @@ config RADIO_RTRACK2 >>> config RADIO_RTRACK2_PORT >>> hex "RadioTrack II i/o port (0x20c or 0x30c)" >>> depends on RADIO_RTRACK2=y >>> - default "30c" >>> + default "0x30c" >>> help >>> Enter either 0x30c or 0x20c here. The card default is 0x30c, if you >>> haven't changed the jumper setting on the card. >>> @@ -104,7 +104,7 @@ config RADIO_AZTECH >>> config RADIO_AZTECH_PORT >>> hex "Aztech/Packard Bell I/O port (0x350 or 0x358)" >>> depends on RADIO_AZTECH=y >>> - default "350" >>> + default "0x350" >>> help >>> Enter either 0x350 or 0x358 here. The card default is 0x350, if you >>> haven't changed the setting of jumper JP3 on the card. Removing the >>> @@ -133,7 +133,7 @@ config RADIO_GEMTEK >>> config RADIO_GEMTEK_PORT >>> hex "Fixed I/O port (0x20c, 0x30c, 0x24c, 0x34c, 0c24c or 0x28c)" >>> depends on RADIO_GEMTEK=y >>> - default "34c" >>> + default "0x34c" >>> help >>> Enter either 0x20c, 0x30c, 0x24c or 0x34c here. The card default is >>> 0x34c, if you haven't changed the jumper setting on the card. On >>> @@ -237,7 +237,7 @@ config RADIO_TERRATEC >>> config RADIO_TERRATEC_PORT >>> hex "Terratec i/o port (normally 0x590)" >>> depends on RADIO_TERRATEC=y >>> - default "590" >>> + default "0x590" >>> help >>> Fill in the I/O port of your TerraTec FM radio card. If unsure, go >>> with the default. >>> @@ -255,7 +255,7 @@ config RADIO_TRUST >>> config RADIO_TRUST_PORT >>> hex "Trust i/o port (usually 0x350 or 0x358)" >>> depends on RADIO_TRUST=y >>> - default "350" >>> + default "0x350" >>> help >>> Enter the I/O port of your Trust FM radio card. If unsure, try the >>> values "0x350" or "0x358". >>> @@ -278,7 +278,7 @@ config RADIO_TYPHOON >>> config RADIO_TYPHOON_PORT >>> hex "Typhoon I/O port (0x316 or 0x336)" >>> depends on RADIO_TYPHOON=y >>> - default "316" >>> + default "0x316" >>> help >>> Enter the I/O port of your Typhoon or EcoRadio radio card. >>> >>> @@ -312,7 +312,7 @@ config RADIO_ZOLTRIX >>> config RADIO_ZOLTRIX_PORT >>> hex "ZOLTRIX I/O port (0x20c or 0x30c)" >>> depends on RADIO_ZOLTRIX=y >>> - default "20c" >>> + default "0x20c" >>> help >>> Enter the I/O port of your Zoltrix radio card. >>> >> >> ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols 2011-07-15 0:01 ` Mauro Carvalho Chehab @ 2011-07-15 1:39 ` Arnaud Lacombe 0 siblings, 0 replies; 18+ messages in thread From: Arnaud Lacombe @ 2011-07-15 1:39 UTC (permalink / raw) To: Mauro Carvalho Chehab; +Cc: linux-kbuild, Randy Dunlap, Michal Marek Hi, [Add Michal to the Cc: list.] On Thu, Jul 14, 2011 at 8:01 PM, Mauro Carvalho Chehab <mchehab@infradead.org> wrote: > Em 14-07-2011 20:32, Arnaud Lacombe escreveu: >> Hi, >> >> On Thu, Jul 14, 2011 at 2:16 PM, Mauro Carvalho Chehab >> <mchehab@infradead.org> wrote: >>> Em 14-07-2011 14:26, Arnaud Lacombe escreveu: >>>> Cc: Mauro Carvalho Chehab <mchehab@infradead.org> >>>> Cc: Randy Dunlap <rdunlap@xenotime.net> >>>> Signed-off-by: Arnaud Lacombe <lacombar@gmail.com> >>> >>> Arnaud, >>> >>> The patch is ok for me. You can add my acked-by, if you want. >>> >> don't you want to take in though the media/video tree for -next ? > > It seems better if you could put it on your tree, before the patch that broke > the Kconfig. Otherwise, you'll need to wait for my merge upstream, before > being sending yours, to avoid breaking git bisect. > Technically, I do not have any tree, Michal does :) That said, both patch are completely independent and both fix the issue. So you can take this patch, for the sake of having prefixed hexadecimal value when the user is editing the config, in the mean time, Michal can merge the fix. > Anyway, I'm ok to add it into my tree if you prefer this way. > I guess it is the easiest. Btw, Randy's earliest patch will no longer be needed too. Thanks, - Arnaud > Thanks! > Mauro > >> >> - Arnaud >> >>> However, with 3.0-rc7, this patch and/or Kconfig fixes don't seem to >>> be needed. Basically, include/generated/autoconf.h has "0x" on it: >>> >>> $ grep CONFIG_RADIO_RTRACK_PORT */*/* >>> include/config/auto.conf:CONFIG_RADIO_RTRACK_PORT=20f >>> include/generated/autoconf.h:#define CONFIG_RADIO_RTRACK_PORT 0x20f >>> >>> Maybe some patch applied at -next from another tree broke that behavior. >>> >>> IMHO, keeping those values without "0x" at Kconfig seems more intuitive >>> for the end-user, as otherwise a value like "200" would be confusing >>> if this means 200d or 200h. >>> >>> Anyway, those drivers are very old, and very few people likely still >>> use those old hardware. So, I'm fine if you either want to preserve >>> the current way or to change it. >>> >>> Cheers, >>> Mauro. >>> >>>> --- >>>> drivers/media/radio/Kconfig | 16 ++++++++-------- >>>> 1 files changed, 8 insertions(+), 8 deletions(-) >>>> >>>> diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig >>>> index e4c97fd..9cab04d 100644 >>>> --- a/drivers/media/radio/Kconfig >>>> +++ b/drivers/media/radio/Kconfig >>>> @@ -58,7 +58,7 @@ config RADIO_RTRACK >>>> config RADIO_RTRACK_PORT >>>> hex "RadioTrack i/o port (0x20f or 0x30f)" >>>> depends on RADIO_RTRACK=y >>>> - default "20f" >>>> + default "0x20f" >>>> help >>>> Enter either 0x30f or 0x20f here. The card default is 0x30f, if you >>>> haven't changed the jumper setting on the card. >>>> @@ -81,7 +81,7 @@ config RADIO_RTRACK2 >>>> config RADIO_RTRACK2_PORT >>>> hex "RadioTrack II i/o port (0x20c or 0x30c)" >>>> depends on RADIO_RTRACK2=y >>>> - default "30c" >>>> + default "0x30c" >>>> help >>>> Enter either 0x30c or 0x20c here. The card default is 0x30c, if you >>>> haven't changed the jumper setting on the card. >>>> @@ -104,7 +104,7 @@ config RADIO_AZTECH >>>> config RADIO_AZTECH_PORT >>>> hex "Aztech/Packard Bell I/O port (0x350 or 0x358)" >>>> depends on RADIO_AZTECH=y >>>> - default "350" >>>> + default "0x350" >>>> help >>>> Enter either 0x350 or 0x358 here. The card default is 0x350, if you >>>> haven't changed the setting of jumper JP3 on the card. Removing the >>>> @@ -133,7 +133,7 @@ config RADIO_GEMTEK >>>> config RADIO_GEMTEK_PORT >>>> hex "Fixed I/O port (0x20c, 0x30c, 0x24c, 0x34c, 0c24c or 0x28c)" >>>> depends on RADIO_GEMTEK=y >>>> - default "34c" >>>> + default "0x34c" >>>> help >>>> Enter either 0x20c, 0x30c, 0x24c or 0x34c here. The card default is >>>> 0x34c, if you haven't changed the jumper setting on the card. On >>>> @@ -237,7 +237,7 @@ config RADIO_TERRATEC >>>> config RADIO_TERRATEC_PORT >>>> hex "Terratec i/o port (normally 0x590)" >>>> depends on RADIO_TERRATEC=y >>>> - default "590" >>>> + default "0x590" >>>> help >>>> Fill in the I/O port of your TerraTec FM radio card. If unsure, go >>>> with the default. >>>> @@ -255,7 +255,7 @@ config RADIO_TRUST >>>> config RADIO_TRUST_PORT >>>> hex "Trust i/o port (usually 0x350 or 0x358)" >>>> depends on RADIO_TRUST=y >>>> - default "350" >>>> + default "0x350" >>>> help >>>> Enter the I/O port of your Trust FM radio card. If unsure, try the >>>> values "0x350" or "0x358". >>>> @@ -278,7 +278,7 @@ config RADIO_TYPHOON >>>> config RADIO_TYPHOON_PORT >>>> hex "Typhoon I/O port (0x316 or 0x336)" >>>> depends on RADIO_TYPHOON=y >>>> - default "316" >>>> + default "0x316" >>>> help >>>> Enter the I/O port of your Typhoon or EcoRadio radio card. >>>> >>>> @@ -312,7 +312,7 @@ config RADIO_ZOLTRIX >>>> config RADIO_ZOLTRIX_PORT >>>> hex "ZOLTRIX I/O port (0x20c or 0x30c)" >>>> depends on RADIO_ZOLTRIX=y >>>> - default "20c" >>>> + default "0x20c" >>>> help >>>> Enter the I/O port of your Zoltrix radio card. >>>> >>> >>> > > ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols 2011-07-14 17:26 ` [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols Arnaud Lacombe 2011-07-14 18:16 ` Mauro Carvalho Chehab @ 2011-07-24 21:38 ` Arnaud Lacombe 1 sibling, 0 replies; 18+ messages in thread From: Arnaud Lacombe @ 2011-07-24 21:38 UTC (permalink / raw) To: linux-kbuild; +Cc: Arnaud Lacombe, Mauro Carvalho Chehab, Randy Dunlap Hi Mauro, On Thu, Jul 14, 2011 at 1:26 PM, Arnaud Lacombe <lacombar@gmail.com> wrote: > Cc: Mauro Carvalho Chehab <mchehab@infradead.org> > Cc: Randy Dunlap <rdunlap@xenotime.net> > Signed-off-by: Arnaud Lacombe <lacombar@gmail.com> > AFAICS, as of -next-20110722, you never grabbed that patch, any specific reason ? Thanks, - Arnaud > --- > drivers/media/radio/Kconfig | 16 ++++++++-------- > 1 files changed, 8 insertions(+), 8 deletions(-) > > diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig > index e4c97fd..9cab04d 100644 > --- a/drivers/media/radio/Kconfig > +++ b/drivers/media/radio/Kconfig > @@ -58,7 +58,7 @@ config RADIO_RTRACK > config RADIO_RTRACK_PORT > hex "RadioTrack i/o port (0x20f or 0x30f)" > depends on RADIO_RTRACK=y > - default "20f" > + default "0x20f" > help > Enter either 0x30f or 0x20f here. The card default is 0x30f, if you > haven't changed the jumper setting on the card. > @@ -81,7 +81,7 @@ config RADIO_RTRACK2 > config RADIO_RTRACK2_PORT > hex "RadioTrack II i/o port (0x20c or 0x30c)" > depends on RADIO_RTRACK2=y > - default "30c" > + default "0x30c" > help > Enter either 0x30c or 0x20c here. The card default is 0x30c, if you > haven't changed the jumper setting on the card. > @@ -104,7 +104,7 @@ config RADIO_AZTECH > config RADIO_AZTECH_PORT > hex "Aztech/Packard Bell I/O port (0x350 or 0x358)" > depends on RADIO_AZTECH=y > - default "350" > + default "0x350" > help > Enter either 0x350 or 0x358 here. The card default is 0x350, if you > haven't changed the setting of jumper JP3 on the card. Removing the > @@ -133,7 +133,7 @@ config RADIO_GEMTEK > config RADIO_GEMTEK_PORT > hex "Fixed I/O port (0x20c, 0x30c, 0x24c, 0x34c, 0c24c or 0x28c)" > depends on RADIO_GEMTEK=y > - default "34c" > + default "0x34c" > help > Enter either 0x20c, 0x30c, 0x24c or 0x34c here. The card default is > 0x34c, if you haven't changed the jumper setting on the card. On > @@ -237,7 +237,7 @@ config RADIO_TERRATEC > config RADIO_TERRATEC_PORT > hex "Terratec i/o port (normally 0x590)" > depends on RADIO_TERRATEC=y > - default "590" > + default "0x590" > help > Fill in the I/O port of your TerraTec FM radio card. If unsure, go > with the default. > @@ -255,7 +255,7 @@ config RADIO_TRUST > config RADIO_TRUST_PORT > hex "Trust i/o port (usually 0x350 or 0x358)" > depends on RADIO_TRUST=y > - default "350" > + default "0x350" > help > Enter the I/O port of your Trust FM radio card. If unsure, try the > values "0x350" or "0x358". > @@ -278,7 +278,7 @@ config RADIO_TYPHOON > config RADIO_TYPHOON_PORT > hex "Typhoon I/O port (0x316 or 0x336)" > depends on RADIO_TYPHOON=y > - default "316" > + default "0x316" > help > Enter the I/O port of your Typhoon or EcoRadio radio card. > > @@ -312,7 +312,7 @@ config RADIO_ZOLTRIX > config RADIO_ZOLTRIX_PORT > hex "ZOLTRIX I/O port (0x20c or 0x30c)" > depends on RADIO_ZOLTRIX=y > - default "20c" > + default "0x20c" > help > Enter the I/O port of your Zoltrix radio card. > > -- > 1.7.3.4.574.g608b.dirty > > ^ permalink raw reply [flat|nested] 18+ messages in thread
end of thread, other threads:[~2011-07-24 21:38 UTC | newest] Thread overview: 18+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2011-07-10 19:51 [PATCH 1/9] stringify: add HEX_STRING() Randy Dunlap 2011-07-13 21:05 ` Mauro Carvalho Chehab 2011-07-13 21:11 ` Randy Dunlap 2011-07-13 22:04 ` Randy Dunlap 2011-07-13 21:49 ` Arnaud Lacombe 2011-07-13 22:00 ` Randy Dunlap 2011-07-13 22:06 ` Arnaud Lacombe 2011-07-13 22:08 ` Randy Dunlap 2011-07-13 22:13 ` Arnaud Lacombe 2011-07-13 22:17 ` Randy Dunlap 2011-07-14 4:03 ` Arnaud Lacombe 2011-07-14 17:26 ` [PATCH] media/Kconfig: fix hexadecimal prefix for `hex' symbols Arnaud Lacombe 2011-07-14 18:16 ` Mauro Carvalho Chehab 2011-07-14 18:47 ` Arnaud Lacombe 2011-07-14 23:32 ` Arnaud Lacombe 2011-07-15 0:01 ` Mauro Carvalho Chehab 2011-07-15 1:39 ` Arnaud Lacombe 2011-07-24 21:38 ` Arnaud Lacombe
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox