linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* debugging a modern laptop ...
@ 2011-03-23  3:42 Herbert Poetzl
  2011-03-23  4:12 ` Andi Kleen
  2011-03-23 15:04 ` Alan Stern
  0 siblings, 2 replies; 4+ messages in thread
From: Herbert Poetzl @ 2011-03-23  3:42 UTC (permalink / raw)
  To: linux-kernel; +Cc: Bernhard Kaindl, Andi Kleen, linux-usb


Greetings!

I'm trying to evaluate my options on debugging a recent
laptop/notebook/table (and the Linux kernel on it of course) 
from early bootup to diagnostics when the machine has locked
up ...

normally the first thing I would do is to attach a serial
console to monitor the early bootup and have some way to
send sysrq triggers ... but here is the first problem,
the thing might not even have a serial port at all ...

most modern devices have at least one usb port, but as far
as I could figure out via google, there is no support for
console or similar over usb (serial or not) atm
(please feel free to correct me here :)

after some research, I also found a quite antique project
exploiting the ieee1394 DMA feature, called firescope and
after some issues finding the latest version of the tool and
of course getting a firewire cable, there seems to be some
kind of interaction between the monitoring system and the
device in question, but it seems that a few problems exist
and I didn't manage to get any relevant information that
way yet (please let me know if that is still maintained)

finally, ethernet and netconsole, which seems to work
reasonably well, at least for the console logging part but
requires at least a supported 'wired' ethernet interface
and a few tricks to send commands to the device ...
(but only partially suited or early bootup of course)

have I missed something? 

what about bluetooth? (usually requires USB)
what about wireless? (probably quite problematic)

maybe a new kind of debug interface is needed in the 
near future?

any ideas and real world experiences are more than
welcome ...

many thanks in advance,
Herbert


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: debugging a modern laptop ...
  2011-03-23  3:42 debugging a modern laptop Herbert Poetzl
@ 2011-03-23  4:12 ` Andi Kleen
  2011-03-23 15:04 ` Alan Stern
  1 sibling, 0 replies; 4+ messages in thread
From: Andi Kleen @ 2011-03-23  4:12 UTC (permalink / raw)
  To: linux-kernel, Bernhard Kaindl, Andi Kleen, linux-usb

> most modern devices have at least one usb port, but as far
> as I could figure out via google, there is no support for
> console or similar over usb (serial or not) atm
> (please feel free to correct me here :)

There is also USB debugport, but you need a quite expensive cable
(~$100) for it. Usually it only works on one of the USB ports.

> 
> after some research, I also found a quite antique project
> exploiting the ieee1394 DMA feature, called firescope and
> after some issues finding the latest version of the tool and
> of course getting a firewire cable, there seems to be some
> kind of interaction between the monitoring system and the
> device in question, but it seems that a few problems exist
> and I didn't manage to get any relevant information that
> way yet (please let me know if that is still maintained)

It works, but you need to enable it of course. The printk
buffer hasn't changed for a long time.

The only problem often is that it doesn't support memory >4GB,
however it turns out that some LSI chips support >4GB DMA
and with those it works too.

-Andi
-- 
ak@linux.intel.com -- Speaking for myself only.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: debugging a modern laptop ...
  2011-03-23  3:42 debugging a modern laptop Herbert Poetzl
  2011-03-23  4:12 ` Andi Kleen
@ 2011-03-23 15:04 ` Alan Stern
  2011-03-23 15:16   ` Mark Lord
  1 sibling, 1 reply; 4+ messages in thread
From: Alan Stern @ 2011-03-23 15:04 UTC (permalink / raw)
  To: Herbert Poetzl; +Cc: linux-kernel, Bernhard Kaindl, Andi Kleen, linux-usb

On Wed, 23 Mar 2011, Herbert Poetzl wrote:

> 
> Greetings!
> 
> I'm trying to evaluate my options on debugging a recent
> laptop/notebook/table (and the Linux kernel on it of course) 
> from early bootup to diagnostics when the machine has locked
> up ...
> 
> normally the first thing I would do is to attach a serial
> console to monitor the early bootup and have some way to
> send sysrq triggers ... but here is the first problem,
> the thing might not even have a serial port at all ...
> 
> most modern devices have at least one usb port, but as far
> as I could figure out via google, there is no support for
> console or similar over usb (serial or not) atm
> (please feel free to correct me here :)

There _is_ support for a USB console (see CONFIG_USB_SERIAL_CONSOLE).  
However it may not be useful for diagnosing problems during boot,
because obviously the console won't operate until the USB stack is in
place and running.

Alan Stern


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: debugging a modern laptop ...
  2011-03-23 15:04 ` Alan Stern
@ 2011-03-23 15:16   ` Mark Lord
  0 siblings, 0 replies; 4+ messages in thread
From: Mark Lord @ 2011-03-23 15:16 UTC (permalink / raw)
  To: Alan Stern
  Cc: Herbert Poetzl, linux-kernel, Bernhard Kaindl, Andi Kleen, linux-usb

On 11-03-23 11:04 AM, Alan Stern wrote:
> On Wed, 23 Mar 2011, Herbert Poetzl wrote:
> 
>>
>> Greetings!
>>
>> I'm trying to evaluate my options on debugging a recent
>> laptop/notebook/table (and the Linux kernel on it of course) 
>> from early bootup to diagnostics when the machine has locked up ...
..
> There _is_ support for a USB console (see CONFIG_USB_SERIAL_CONSOLE).  
> However it may not be useful for diagnosing problems during boot,
> because obviously the console won't operate until the USB stack is in
> place and running.
..

If you are lucky enough to have an ExpressCard slot on the notebook,
then lots of eBay sellers offer "Oxford chipset" serial/parallel ports
in ExpressCard format.

These provide "true" bus serial ports, which can be used as Linux consoles
for low level kernel debugging, logs, panics, etc..

As a bonus, he parallel ports from the same chips can be used
for homebrew JTAG adapters.

-ml

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-03-23 15:16 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-23  3:42 debugging a modern laptop Herbert Poetzl
2011-03-23  4:12 ` Andi Kleen
2011-03-23 15:04 ` Alan Stern
2011-03-23 15:16   ` Mark Lord

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).