From: Tom Rini <trini@kernel.crashing.org>
To: George Anzinger <george@mvista.com>
Cc: "Amit S. Kale" <amitkale@emsyssoft.com>,
Pavel Machek <pavel@ucw.cz>,
Kernel Mailing List <linux-kernel@vger.kernel.org>,
kgdb-bugreport@lists.sourceforge.net
Subject: Re: [Kgdb-bugreport] [PATCH] Kill kgdb_serial
Date: Thu, 4 Mar 2004 16:17:37 -0700 [thread overview]
Message-ID: <20040304231737.GJ26065@smtp.west.cox.net> (raw)
In-Reply-To: <4047B67A.4050609@mvista.com>
On Thu, Mar 04, 2004 at 03:06:34PM -0800, George Anzinger wrote:
> Tom Rini wrote:
> >On Thu, Mar 04, 2004 at 10:11:39AM +0530, Amit S. Kale wrote:
> >
> >>On Wednesday 03 Mar 2004 8:46 pm, Tom Rini wrote:
> >>
> >>>On Wed, Mar 03, 2004 at 11:13:02AM +0530, Amit S. Kale wrote:
> >
> >[snip]
> >
> >>>>kgdb_serial isn't ugly. It's just a function switch, similar to several
> >>>>of them in the kernel. ppc is ugly, but that's anyway the case because
> >>>>of
> >>>>so many varieties of ppc. If we are trying to make ppc code clean, it
> >>>>makes more sense to move this weak function thing into ppc specific
> >>>>files
> >>>>IMHO.
> >>>
> >>>I think you missed the point. The problem isn't with providing weak
> >>>functions, the problem is trying to set the function pointer. PPC
> >>>becomes quite clean since the next step is to kill off
> >>>PPC_SIMPLE_SERIAL and just have kgdb_read/write_debug_char in the
> >>>relevant serial drivers.
> >>
> >>We can still have one single hardcoded function pointer for ppc and manage
> >>the rest in ppc specific files.
> >
> >
> >I think you're still missing the point.
> >
> >Regardless, the solution to this is what dwmw2 suggested on IRC I
> >believe, as this should remove all of the #ifdef mess.
>
> I am afraid I don't quite understand what he was saying other than early
> init stuff. On of the problems with trying early init stuff, by the way,
> is that a lot of things depend on having alloc up and that happens rather
> late in the game.
I assume you aren't talking about kgdb stuff here (or what would be the
point of going so early) but I believe he was talking about allowing for
stuff that could be done early, to be done early.
> But back to the method. Is he/are you suggesting that the init code plug
> the array of functions into the kgdb table? This could be done by
> providing a register function in kgdb to register an i/o method. Pass it a
> pointer to a struc of entry points, keep the pointers in an array, etc.
> All that is left is to define the default in some simple and clean way, a
> way that might be overridden at command line parse time and so on.
What I'm suggesting is that we don't need this table stuff at all.
Roughly:
- Call kgdb_entry(), minus the kgdb_serial->hook(), as early as
possible.
- We do early parsing of some cmd opts (this I believe is __early_setup)
- This means that to use kgdboe you _must_ pass kgdboe=whatever, same
for 8250, etc. This would also do kgdb_serial = kgdboe_serial, or
whatever.
- 8250, kgdboe, etc, must be able to init themselves.
- If ('gdb' || 'kgdbwait') && kgdb_serial != NULL -> breakpoint();
--
Tom Rini
http://gate.crashing.org/~trini/
next prev parent reply other threads:[~2004-03-04 23:17 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-03-02 21:39 Tom Rini
2004-03-02 22:02 ` [Kgdb-bugreport] " George Anzinger
2004-03-02 22:11 ` Tom Rini
2004-03-02 22:31 ` Pavel Machek
2004-03-02 22:41 ` Tom Rini
2004-03-02 23:00 ` Tom Rini
2004-03-02 23:35 ` Pavel Machek
2004-03-03 15:22 ` Tom Rini
2004-03-03 15:51 ` Pavel Machek
2004-03-03 16:04 ` Tom Rini
2004-03-04 0:34 ` George Anzinger
2004-03-04 5:01 ` Amit S. Kale
2004-03-04 22:02 ` George Anzinger
2004-03-04 22:48 ` Tom Rini
2004-03-02 23:46 ` George Anzinger
2004-03-02 23:52 ` Tom Rini
2004-03-03 0:36 ` George Anzinger
2004-03-03 15:20 ` Tom Rini
2004-03-04 0:30 ` George Anzinger
2004-03-03 5:43 ` Amit S. Kale
2004-03-03 15:16 ` Tom Rini
2004-03-04 0:27 ` George Anzinger
2004-03-04 15:17 ` Tom Rini
2004-03-04 22:18 ` George Anzinger
2004-03-04 22:49 ` Tom Rini
2004-03-04 4:41 ` Amit S. Kale
2004-03-04 15:27 ` Tom Rini
2004-03-04 23:06 ` George Anzinger
2004-03-04 23:17 ` Tom Rini [this message]
2004-03-11 21:33 ` George Anzinger
2004-03-11 22:33 ` Tom Rini
2004-03-11 22:53 ` George Anzinger
2004-03-11 23:00 ` Tom Rini
2004-03-11 23:46 ` George Anzinger
2004-03-12 4:52 ` Amit S. Kale
2004-03-12 4:48 ` Amit S. Kale
2004-03-03 15:26 ` Matt Mackall
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=20040304231737.GJ26065@smtp.west.cox.net \
--to=trini@kernel.crashing.org \
--cc=amitkale@emsyssoft.com \
--cc=george@mvista.com \
--cc=kgdb-bugreport@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
--cc=pavel@ucw.cz \
/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
all inboxes | Powered by JetHome®