From: David Brownell <david-b@pacbell.net>
To: Stas Sergeev <stsp@aknet.ru>, akpm@linux-foundation.org
Cc: ambx1@neo.rr.com, bjorn.helgaas@hp.com, mingo@elte.hu,
tglx@linutronix.de, Russell King <rmk+lkml@arm.linux.org.uk>,
Linux kernel <linux-kernel@vger.kernel.org>
Subject: Re: [patch][resend] provide rtc_cmos platform device, take 2
Date: Wed, 28 May 2008 23:27:08 -0700 [thread overview]
Message-ID: <200805282327.08981.david-b@pacbell.net> (raw)
In-Reply-To: <483BEF1A.3080808@aknet.ru>
On Tuesday 27 May 2008, Stas Sergeev wrote:
> --- a/arch/x86/kernel/rtc.c
> +++ b/arch/x86/kernel/rtc.c
> @@ -4,9 +4,12 @@
> #include <linux/acpi.h>
> #include <linux/bcd.h>
> #include <linux/mc146818rtc.h>
> +#include <linux/platform_device.h>
> +#include <linux/pnp.h>
>
> #include <asm/time.h>
> #include <asm/vsyscall.h>
> +#include <asm/mc146818rtc.h>
The <asm/mc146818rtc.h> isn't needed, since it's automatically
included via <linux/mc146818rtc.h> ... see right at the top.
And for good fun, notice how the asm file includes the linux
version ... seems like a cleanup would be nice someday. :)
> --- a/drivers/rtc/rtc-cmos.c
> +++ b/drivers/rtc/rtc-cmos.c
> @@ -958,20 +946,33 @@ static struct platform_driver cmos_platform_driver = {
>
> static int __init cmos_init(void)
> {
> +#ifdef CONFIG_PNP
> + if (pnp_platform_devices)
> + return pnp_register_driver(&cmos_pnp_driver);
> + else
> + return platform_driver_probe(&cmos_platform_driver,
> + cmos_platform_probe);
> +#else
> return platform_driver_probe(&cmos_platform_driver,
> cmos_platform_probe);
> +#endif /* CONFIG_PNP */
> }
> module_init(cmos_init);
That's kind of ugly, but not wrong.
My only question is whether that resolves the problem Russell was
reporting. I think his situation needed to register *both* types
of bus glue (but I never saw his patch). If we're going to fix this,
best merge just one patch...
- Dave
prev parent reply other threads:[~2008-05-29 6:27 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200805212334.m4LNY42M006425@imap1.linux-foundation.org>
2008-05-23 5:02 ` [patch] " Stas Sergeev
2008-05-27 11:23 ` [patch][resend] " Stas Sergeev
2008-05-28 23:36 ` Andrew Morton
2008-05-29 4:52 ` Stas Sergeev
2008-05-29 14:54 ` Bjorn Helgaas
2008-05-30 4:12 ` Stas Sergeev
2008-05-30 15:52 ` Bjorn Helgaas
2008-06-02 9:46 ` Ingo Molnar
2008-06-02 9:53 ` Russell King
2008-05-29 6:27 ` David Brownell [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200805282327.08981.david-b@pacbell.net \
--to=david-b@pacbell.net \
--cc=akpm@linux-foundation.org \
--cc=ambx1@neo.rr.com \
--cc=bjorn.helgaas@hp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=rmk+lkml@arm.linux.org.uk \
--cc=stsp@aknet.ru \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome