* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. @ 2013-05-20 5:42 Chen Gang 2013-05-20 9:10 ` Will Deacon 0 siblings, 1 reply; 11+ messages in thread From: Chen Gang @ 2013-05-20 5:42 UTC (permalink / raw) To: linux-arm-kernel Add the extern variable 'screen_info' according to arm32 has done. The related error: drivers/video/console/vgacon.c:1305: undefined reference to `screen_info' Signed-off-by: Chen Gang <gang.chen@asianux.com> --- arch/arm64/kernel/setup.c | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/arch/arm64/kernel/setup.c b/arch/arm64/kernel/setup.c index add6ea6..1055992 100644 --- a/arch/arm64/kernel/setup.c +++ b/arch/arm64/kernel/setup.c @@ -374,3 +374,14 @@ const struct seq_operations cpuinfo_op = { .stop = c_stop, .show = c_show }; + +#if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_DUMMY_CONSOLE) +struct screen_info screen_info = { + .orig_video_lines = 30, + .orig_video_cols = 80, + .orig_video_mode = 0, + .orig_video_ega_bx = 0, + .orig_video_isVGA = 1, + .orig_video_points = 8 +}; +#endif -- 1.7.7.6 ^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-20 5:42 [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using Chen Gang @ 2013-05-20 9:10 ` Will Deacon 2013-05-21 3:15 ` Chen Gang 0 siblings, 1 reply; 11+ messages in thread From: Will Deacon @ 2013-05-20 9:10 UTC (permalink / raw) To: linux-arm-kernel Hi Chen, On Mon, May 20, 2013 at 06:42:46AM +0100, Chen Gang wrote: > > Add the extern variable 'screen_info' according to arm32 has done. > > The related error: > drivers/video/console/vgacon.c:1305: undefined reference to `screen_info' > > > Signed-off-by: Chen Gang <gang.chen@asianux.com> > --- > arch/arm64/kernel/setup.c | 11 +++++++++++ > 1 files changed, 11 insertions(+), 0 deletions(-) > > diff --git a/arch/arm64/kernel/setup.c b/arch/arm64/kernel/setup.c > index add6ea6..1055992 100644 > --- a/arch/arm64/kernel/setup.c > +++ b/arch/arm64/kernel/setup.c > @@ -374,3 +374,14 @@ const struct seq_operations cpuinfo_op = { > .stop = c_stop, > .show = c_show > }; > + > +#if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_DUMMY_CONSOLE) > +struct screen_info screen_info = { > + .orig_video_lines = 30, > + .orig_video_cols = 80, > + .orig_video_mode = 0, > + .orig_video_ega_bx = 0, > + .orig_video_isVGA = 1, > + .orig_video_points = 8 > +}; > +#endif I think it would be better if we added a something like CONFIG_HAVE_VGA_CONSOLE, which VGA_CONSOLE can then depend on. Architectures like x86 can then select the former, and we can remove the long list of architectures from the current option. Will ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-20 9:10 ` Will Deacon @ 2013-05-21 3:15 ` Chen Gang 2013-05-21 6:57 ` Geert Uytterhoeven 0 siblings, 1 reply; 11+ messages in thread From: Chen Gang @ 2013-05-21 3:15 UTC (permalink / raw) To: linux-arm-kernel On 05/20/2013 05:10 PM, Will Deacon wrote: > Hi Chen, > > On Mon, May 20, 2013 at 06:42:46AM +0100, Chen Gang wrote: >> >> Add the extern variable 'screen_info' according to arm32 has done. >> >> The related error: >> drivers/video/console/vgacon.c:1305: undefined reference to `screen_info' >> >> >> Signed-off-by: Chen Gang <gang.chen@asianux.com> >> --- >> arch/arm64/kernel/setup.c | 11 +++++++++++ >> 1 files changed, 11 insertions(+), 0 deletions(-) >> >> diff --git a/arch/arm64/kernel/setup.c b/arch/arm64/kernel/setup.c >> index add6ea6..1055992 100644 >> --- a/arch/arm64/kernel/setup.c >> +++ b/arch/arm64/kernel/setup.c >> @@ -374,3 +374,14 @@ const struct seq_operations cpuinfo_op = { >> .stop = c_stop, >> .show = c_show >> }; >> + >> +#if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_DUMMY_CONSOLE) >> +struct screen_info screen_info = { >> + .orig_video_lines = 30, >> + .orig_video_cols = 80, >> + .orig_video_mode = 0, >> + .orig_video_ega_bx = 0, >> + .orig_video_isVGA = 1, >> + .orig_video_points = 8 >> +}; >> +#endif > > I think it would be better if we added a something like > CONFIG_HAVE_VGA_CONSOLE, which VGA_CONSOLE can then depend on. Architectures > like x86 can then select the former, and we can remove the long list of > architectures from the current option. > I guess your meaning is: under arm64, actually, need not support 'VGA_CONSOLE', and 'screen_info' is useless. So better to define 'CONFIG_HAVE_VGA_CONSOLE' which 'VGA_CONSOLE' can depend on it, and in arm64, we do not define CONFIG_HAVE_VGA_CONSOLE. Is it correct ? If so, I recommend to add depend item for VGA_CONSOLE directly: -------------------diff begin---------------------------------- diff --git a/drivers/video/console/Kconfig b/drivers/video/console/Kconfig index bc922c4..b759157 100644 --- a/drivers/video/console/Kconfig +++ b/drivers/video/console/Kconfig @@ -6,7 +6,7 @@ menu "Console display driver support" config VGA_CONSOLE bool "VGA text console" if EXPERT || !X86 - depends on !4xx && !8xx && !SPARC && !M68K && !PARISC && !FRV && !SUPERH && !BLACKFIN && !AVR32 && !MN10300 && (!ARM || ARCH_FOOTBRIDGE || ARCH_INTEGRATOR || ARCH_NETWINDER) + depends on !4xx && !8xx && !SPARC && !M68K && !PARISC && !FRV && !SUPERH && !BLACKFIN && !AVR32 && !MN10300 && !ARM64 && (!ARM || ARCH_FOOTBRIDGE || ARCH_INTEGRATOR || ARCH_NETWINDER) default y help Saying Y here will allow you to use Linux in text mode through a -------------------diff end------------------------------------ Thanks. -- Chen Gang Asianux Corporation ^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-21 3:15 ` Chen Gang @ 2013-05-21 6:57 ` Geert Uytterhoeven 2013-05-21 7:51 ` Chen Gang 0 siblings, 1 reply; 11+ messages in thread From: Geert Uytterhoeven @ 2013-05-21 6:57 UTC (permalink / raw) To: linux-arm-kernel On Tue, May 21, 2013 at 5:15 AM, Chen Gang <gang.chen@asianux.com> wrote: >> I think it would be better if we added a something like >> CONFIG_HAVE_VGA_CONSOLE, which VGA_CONSOLE can then depend on. Architectures >> like x86 can then select the former, and we can remove the long list of >> architectures from the current option. > > I guess your meaning is: > > under arm64, actually, need not support 'VGA_CONSOLE', and 'screen_info' is useless. > So better to define 'CONFIG_HAVE_VGA_CONSOLE' which 'VGA_CONSOLE' can depend on it, and in arm64, we do not define CONFIG_HAVE_VGA_CONSOLE. > > Is it correct ? No, you missed "and we can remove the long list of architectures from the current option". > If so, I recommend to add depend item for VGA_CONSOLE directly: I strongly support CONFIG_HAVE_VGA_CONSOLE. Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at 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] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-21 6:57 ` Geert Uytterhoeven @ 2013-05-21 7:51 ` Chen Gang 2013-05-21 9:03 ` Will Deacon 2013-05-21 11:07 ` Geert Uytterhoeven 0 siblings, 2 replies; 11+ messages in thread From: Chen Gang @ 2013-05-21 7:51 UTC (permalink / raw) To: linux-arm-kernel On 05/21/2013 02:57 PM, Geert Uytterhoeven wrote: > On Tue, May 21, 2013 at 5:15 AM, Chen Gang <gang.chen@asianux.com> wrote: >>> >> I think it would be better if we added a something like >>> >> CONFIG_HAVE_VGA_CONSOLE, which VGA_CONSOLE can then depend on. Architectures >>> >> like x86 can then select the former, and we can remove the long list of >>> >> architectures from the current option. >> > >> > I guess your meaning is: >> > >> > under arm64, actually, need not support 'VGA_CONSOLE', and 'screen_info' is useless. >> > So better to define 'CONFIG_HAVE_VGA_CONSOLE' which 'VGA_CONSOLE' can depend on it, and in arm64, we do not define CONFIG_HAVE_VGA_CONSOLE. >> > >> > Is it correct ? > No, you missed "and we can remove the long list of architectures from the > current option". > OK, thanks. Is it correct: "it is unnecessary to add 'screen_info' to the code, for arm64 will never support 'VGA_CONSOLE'" ? >> > If so, I recommend to add depend item for VGA_CONSOLE directly: > I strongly support CONFIG_HAVE_VGA_CONSOLE. For me, I still recommend add 'ARM64' in the long list of architectures for 'VGA_CONSOLE', I have 3 reasons, please check: a. current implementation only changes one area which only related with arm64 and 'VGA_CONSOLE', but if use 'CONFIG_HAVE_VGA_CONSOLE', that will touch many multiple platforms dependency, at least we need discuss about it with multiple platforms guys for it, firstly. b. We can find some cases to use CONFIG_HAVE_* as dpend on, but I can not find any cases which let CONFIG_'samename' depend on CONFIG_HAVE_'samename'. c. The original way still has effect, although it seems not quit beautiful, but it is correct and still clear for readers, it is still sustainable. Thanks. -- Chen Gang Asianux Corporation ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-21 7:51 ` Chen Gang @ 2013-05-21 9:03 ` Will Deacon 2013-05-21 10:13 ` Chen Gang 2013-05-21 11:07 ` Geert Uytterhoeven 1 sibling, 1 reply; 11+ messages in thread From: Will Deacon @ 2013-05-21 9:03 UTC (permalink / raw) To: linux-arm-kernel On Tue, May 21, 2013 at 08:51:39AM +0100, Chen Gang wrote: > On 05/21/2013 02:57 PM, Geert Uytterhoeven wrote: > > On Tue, May 21, 2013 at 5:15 AM, Chen Gang <gang.chen@asianux.com> wrote: > >>> >> I think it would be better if we added a something like > >>> >> CONFIG_HAVE_VGA_CONSOLE, which VGA_CONSOLE can then depend on. Architectures > >>> >> like x86 can then select the former, and we can remove the long list of > >>> >> architectures from the current option. > >> > > >> > I guess your meaning is: > >> > > >> > under arm64, actually, need not support 'VGA_CONSOLE', and 'screen_info' is useless. > >> > So better to define 'CONFIG_HAVE_VGA_CONSOLE' which 'VGA_CONSOLE' can depend on it, and in arm64, we do not define CONFIG_HAVE_VGA_CONSOLE. > >> > > >> > Is it correct ? > > No, you missed "and we can remove the long list of architectures from the > > current option". > > > > OK, thanks. > > Is it correct: "it is unnecessary to add 'screen_info' to the code, for > arm64 will never support 'VGA_CONSOLE'" ? We can add the screen_info if and when we need to support a VGA console. In the meantime, let's not add things on a whim. > >> > If so, I recommend to add depend item for VGA_CONSOLE directly: > > I strongly support CONFIG_HAVE_VGA_CONSOLE. > > For me, I still recommend add 'ARM64' in the long list of architectures > for 'VGA_CONSOLE', I have 3 reasons, please check: > > a. current implementation only changes one area which only related with > arm64 and 'VGA_CONSOLE', but if use 'CONFIG_HAVE_VGA_CONSOLE', that will > touch many multiple platforms dependency, at least we need discuss about > it with multiple platforms guys for it, firstly. That's a weak argument. You might as well propose the cleanup and see what people say. > b. We can find some cases to use CONFIG_HAVE_* as dpend on, but I can > not find any cases which let CONFIG_'samename' depend on > CONFIG_HAVE_'samename'. Erm. PERF_EVENTS, BPF_JIT, IDE, ...? > c. The original way still has effect, although it seems not quit > beautiful, but it is correct and still clear for readers, it is still > sustainable. Sure, it works, but we're just contributing to the mess that's been built up ever time another architecture has done the same thing. It's not hard to try and clean it up. Will ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-21 9:03 ` Will Deacon @ 2013-05-21 10:13 ` Chen Gang 2013-05-21 13:15 ` Catalin Marinas 0 siblings, 1 reply; 11+ messages in thread From: Chen Gang @ 2013-05-21 10:13 UTC (permalink / raw) To: linux-arm-kernel On 05/21/2013 05:03 PM, Will Deacon wrote: > On Tue, May 21, 2013 at 08:51:39AM +0100, Chen Gang wrote: >> On 05/21/2013 02:57 PM, Geert Uytterhoeven wrote: >>> On Tue, May 21, 2013 at 5:15 AM, Chen Gang <gang.chen@asianux.com> wrote: >>>>>>> I think it would be better if we added a something like >>>>>>> CONFIG_HAVE_VGA_CONSOLE, which VGA_CONSOLE can then depend on. Architectures >>>>>>> like x86 can then select the former, and we can remove the long list of >>>>>>> architectures from the current option. >>>>> >>>>> I guess your meaning is: >>>>> >>>>> under arm64, actually, need not support 'VGA_CONSOLE', and 'screen_info' is useless. >>>>> So better to define 'CONFIG_HAVE_VGA_CONSOLE' which 'VGA_CONSOLE' can depend on it, and in arm64, we do not define CONFIG_HAVE_VGA_CONSOLE. >>>>> >>>>> Is it correct ? >>> No, you missed "and we can remove the long list of architectures from the >>> current option". >>> >> >> OK, thanks. >> >> Is it correct: "it is unnecessary to add 'screen_info' to the code, for >> arm64 will never support 'VGA_CONSOLE'" ? > > We can add the screen_info if and when we need to support a VGA console. In > the meantime, let's not add things on a whim. > OK, thanks. At least now (for our case), need not add 'screen_info', is it correct ? >>>>> If so, I recommend to add depend item for VGA_CONSOLE directly: >>> I strongly support CONFIG_HAVE_VGA_CONSOLE. >> >> For me, I still recommend add 'ARM64' in the long list of architectures >> for 'VGA_CONSOLE', I have 3 reasons, please check: >> >> a. current implementation only changes one area which only related with >> arm64 and 'VGA_CONSOLE', but if use 'CONFIG_HAVE_VGA_CONSOLE', that will >> touch many multiple platforms dependency, at least we need discuss about >> it with multiple platforms guys for it, firstly. > > That's a weak argument. You might as well propose the cleanup and see what > people say. > Hmm.. I think at least, we need discuss it with the 'final applier' firstly (and now, I even do not know who is the 'final applier'). >> b. We can find some cases to use CONFIG_HAVE_* as dpend on, but I can >> not find any cases which let CONFIG_'samename' depend on >> CONFIG_HAVE_'samename'. > > Erm. PERF_EVENTS, BPF_JIT, IDE, ...? > CONFIG_PERF_EVENTS is not directly depend on CONFIG_HAVE_PERF_EVENTS. CONFIG_BPF_JIT is not directly depend on CONFIG_HAVE_BPF_JIT. CONFIG_IDE is not directly depend on CONFIG_HAVE_IDE. ... But I guess what we will do is to let "CONFIG_VGA_CONSOLE is directly depend on CONFIG_HAVE_VGA_CONSOLE". So I think we really need discuss it firstly with the 'final applier'. >> c. The original way still has effect, although it seems not quit >> beautiful, but it is correct and still clear for readers, it is still >> sustainable. > > Sure, it works, but we're just contributing to the mess that's been built up > ever time another architecture has done the same thing. It's not hard to try > and clean it up. > Can we separate into 2 patches ?. One is for current compiling issue with allmodconfig (the priority is a litter higher), the other is for fixup patch (the priority is lower). ;-) BTW: In fact, if we really need send the related fixup patch, I am also unwilling to do that, I guess (in my experience), the fixup patch like that, will never be applied. :-( Thanks. -- Chen Gang Asianux Corporation ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-21 10:13 ` Chen Gang @ 2013-05-21 13:15 ` Catalin Marinas 2013-05-22 0:50 ` Chen Gang 0 siblings, 1 reply; 11+ messages in thread From: Catalin Marinas @ 2013-05-21 13:15 UTC (permalink / raw) To: linux-arm-kernel On Tue, May 21, 2013 at 11:13:08AM +0100, Chen Gang wrote: > On 05/21/2013 05:03 PM, Will Deacon wrote: > > On Tue, May 21, 2013 at 08:51:39AM +0100, Chen Gang wrote: > >> For me, I still recommend add 'ARM64' in the long list of architectures > >> for 'VGA_CONSOLE', I have 3 reasons, please check: > >> > >> a. current implementation only changes one area which only related with > >> arm64 and 'VGA_CONSOLE', but if use 'CONFIG_HAVE_VGA_CONSOLE', that will > >> touch many multiple platforms dependency, at least we need discuss about > >> it with multiple platforms guys for it, firstly. > > > > That's a weak argument. You might as well propose the cleanup and see what > > people say. > > Hmm.. I think at least, we need discuss it with the 'final applier' > firstly (and now, I even do not know who is the 'final applier'). Well, you can post the patch to linux-arch, cc'ing the arch maintainers whose Kconfig files you touch. If there are no comments, it will most likely be picked by Andrew Morton and sent to Linus (make sure you cc Andrew as well). -- Catalin ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-21 13:15 ` Catalin Marinas @ 2013-05-22 0:50 ` Chen Gang 0 siblings, 0 replies; 11+ messages in thread From: Chen Gang @ 2013-05-22 0:50 UTC (permalink / raw) To: linux-arm-kernel On 05/21/2013 09:15 PM, Catalin Marinas wrote: > On Tue, May 21, 2013 at 11:13:08AM +0100, Chen Gang wrote: >> > On 05/21/2013 05:03 PM, Will Deacon wrote: >>> > > On Tue, May 21, 2013 at 08:51:39AM +0100, Chen Gang wrote: >>>> > >> For me, I still recommend add 'ARM64' in the long list of architectures >>>> > >> for 'VGA_CONSOLE', I have 3 reasons, please check: >>>> > >> >>>> > >> a. current implementation only changes one area which only related with >>>> > >> arm64 and 'VGA_CONSOLE', but if use 'CONFIG_HAVE_VGA_CONSOLE', that will >>>> > >> touch many multiple platforms dependency, at least we need discuss about >>>> > >> it with multiple platforms guys for it, firstly. >>> > > >>> > > That's a weak argument. You might as well propose the cleanup and see what >>> > > people say. >> > >> > Hmm.. I think at least, we need discuss it with the 'final applier' >> > firstly (and now, I even do not know who is the 'final applier'). > Well, you can post the patch to linux-arch, cc'ing the arch maintainers > whose Kconfig files you touch. If there are no comments, it will most > likely be picked by Andrew Morton and sent to Linus (make sure you cc > Andrew as well). OK, thanks. I will do with PARPORT_PC firstly, I think, it is a better candidate than VGA_CONSOLE. And excuse me, I have to do another things now, and I think I should finish the PARPORT_PC within this week. Thanks. -- Chen Gang Asianux Corporation ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-21 7:51 ` Chen Gang 2013-05-21 9:03 ` Will Deacon @ 2013-05-21 11:07 ` Geert Uytterhoeven 2013-05-21 11:40 ` Chen Gang 1 sibling, 1 reply; 11+ messages in thread From: Geert Uytterhoeven @ 2013-05-21 11:07 UTC (permalink / raw) To: linux-arm-kernel On Tue, May 21, 2013 at 9:51 AM, Chen Gang <gang.chen@asianux.com> wrote: > On 05/21/2013 02:57 PM, Geert Uytterhoeven wrote: >> On Tue, May 21, 2013 at 5:15 AM, Chen Gang <gang.chen@asianux.com> wrote: >>>> >> I think it would be better if we added a something like >>>> >> CONFIG_HAVE_VGA_CONSOLE, which VGA_CONSOLE can then depend on. Architectures >>>> >> like x86 can then select the former, and we can remove the long list of >>>> >> architectures from the current option. >>> > >>> > I guess your meaning is: >>> > >>> > under arm64, actually, need not support 'VGA_CONSOLE', and 'screen_info' is useless. >>> > So better to define 'CONFIG_HAVE_VGA_CONSOLE' which 'VGA_CONSOLE' can depend on it, and in arm64, we do not define CONFIG_HAVE_VGA_CONSOLE. >>> > >>> > Is it correct ? >> No, you missed "and we can remove the long list of architectures from the >> current option". >> > > OK, thanks. > > Is it correct: "it is unnecessary to add 'screen_info' to the code, for > arm64 will never support 'VGA_CONSOLE'" ? On arm (not (yet?) arm64), drivers/video/console/dummycon.c also uses screen_info. The default text mode resolution may come from atags. >>> > If so, I recommend to add depend item for VGA_CONSOLE directly: >> I strongly support CONFIG_HAVE_VGA_CONSOLE. > > For me, I still recommend add 'ARM64' in the long list of architectures > for 'VGA_CONSOLE', I have 3 reasons, please check: > > a. current implementation only changes one area which only related with > arm64 and 'VGA_CONSOLE', but if use 'CONFIG_HAVE_VGA_CONSOLE', that will > touch many multiple platforms dependency, at least we need discuss about > it with multiple platforms guys for it, firstly. Sure. But this can be one cleanup patch. > b. We can find some cases to use CONFIG_HAVE_* as dpend on, but I can > not find any cases which let CONFIG_'samename' depend on > CONFIG_HAVE_'samename'. A similar mechanism is used for PC-style floppy support, but the naming is different, cfr. drivers/block/Kconfig: config BLK_DEV_FD tristate "Normal floppy disk support" depends on ARCH_MAY_HAVE_PC_FDC so perhaps ARCH_MAY_HAVE_VGA? PARPORT_PC could use the same mechanism. > c. The original way still has effect, although it seems not quit > beautiful, but it is correct and still clear for readers, it is still > sustainable. Most/every new architecture needs to add a depend to it. BTW, I should have done this when sending out the patch to add CRIS to the list of dependencies... Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at 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] 11+ messages in thread
* [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using. 2013-05-21 11:07 ` Geert Uytterhoeven @ 2013-05-21 11:40 ` Chen Gang 0 siblings, 0 replies; 11+ messages in thread From: Chen Gang @ 2013-05-21 11:40 UTC (permalink / raw) To: linux-arm-kernel On 05/21/2013 07:07 PM, Geert Uytterhoeven wrote: > On Tue, May 21, 2013 at 9:51 AM, Chen Gang <gang.chen@asianux.com> wrote: >> > On 05/21/2013 02:57 PM, Geert Uytterhoeven wrote: >>> >> On Tue, May 21, 2013 at 5:15 AM, Chen Gang <gang.chen@asianux.com> wrote: >>>>>>> >>>> >> I think it would be better if we added a something like >>>>>>> >>>> >> CONFIG_HAVE_VGA_CONSOLE, which VGA_CONSOLE can then depend on. Architectures >>>>>>> >>>> >> like x86 can then select the former, and we can remove the long list of >>>>>>> >>>> >> architectures from the current option. >>>>> >>> > >>>>> >>> > I guess your meaning is: >>>>> >>> > >>>>> >>> > under arm64, actually, need not support 'VGA_CONSOLE', and 'screen_info' is useless. >>>>> >>> > So better to define 'CONFIG_HAVE_VGA_CONSOLE' which 'VGA_CONSOLE' can depend on it, and in arm64, we do not define CONFIG_HAVE_VGA_CONSOLE. >>>>> >>> > >>>>> >>> > Is it correct ? >>> >> No, you missed "and we can remove the long list of architectures from the >>> >> current option". >>> >> >> > >> > OK, thanks. >> > >> > Is it correct: "it is unnecessary to add 'screen_info' to the code, for >> > arm64 will never support 'VGA_CONSOLE'" ? > On arm (not (yet?) arm64), drivers/video/console/dummycon.c also uses > screen_info. The default text mode resolution may come from atags. > Oh, really it is, we need consider them both. >>>>> >>> > If so, I recommend to add depend item for VGA_CONSOLE directly: >>> >> I strongly support CONFIG_HAVE_VGA_CONSOLE. >> > >> > For me, I still recommend add 'ARM64' in the long list of architectures >> > for 'VGA_CONSOLE', I have 3 reasons, please check: >> > >> > a. current implementation only changes one area which only related with >> > arm64 and 'VGA_CONSOLE', but if use 'CONFIG_HAVE_VGA_CONSOLE', that will >> > touch many multiple platforms dependency, at least we need discuss about >> > it with multiple platforms guys for it, firstly. > Sure. But this can be one cleanup patch. > Hmm..., it seems so, but I think we'd better to discuss it with the 'final applier' firstly. >> > b. We can find some cases to use CONFIG_HAVE_* as dpend on, but I can >> > not find any cases which let CONFIG_'samename' depend on >> > CONFIG_HAVE_'samename'. > A similar mechanism is used for PC-style floppy support, but the naming > is different, cfr. drivers/block/Kconfig: > > config BLK_DEV_FD > tristate "Normal floppy disk support" > depends on ARCH_MAY_HAVE_PC_FDC > > so perhaps ARCH_MAY_HAVE_VGA? > > PARPORT_PC could use the same mechanism. > Oh, really, it is !! Hmm.., most of current machines do not have floppy, now, and will be less and less in the future, it has to use the variables in this way to avoid a very very very long list (not only include architectures, but also include the each features companition) !! But for VIDEO_CONSOL, most of machines need it, and will be more and more in the future (maybe arm64 will also support it, too, in the future). So... >> > c. The original way still has effect, although it seems not quit >> > beautiful, but it is correct and still clear for readers, it is still >> > sustainable. > Most/every new architecture needs to add a depend to it. > > BTW, I should have done this when sending out the patch to add CRIS to the > list of dependencies... I suggest better to discuss it with the 'final applier' firstly. Good Luck !! Thanks. -- Chen Gang Asianux Corporation ^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2013-05-22 0:50 UTC | newest] Thread overview: 11+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2013-05-20 5:42 [PATCH] arm64: kernel: need extern variable 'screen_info' for related driver using Chen Gang 2013-05-20 9:10 ` Will Deacon 2013-05-21 3:15 ` Chen Gang 2013-05-21 6:57 ` Geert Uytterhoeven 2013-05-21 7:51 ` Chen Gang 2013-05-21 9:03 ` Will Deacon 2013-05-21 10:13 ` Chen Gang 2013-05-21 13:15 ` Catalin Marinas 2013-05-22 0:50 ` Chen Gang 2013-05-21 11:07 ` Geert Uytterhoeven 2013-05-21 11:40 ` Chen Gang
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).