kdb
[Top] [All Lists]

Re: [PATCH] Add support for USB Keyboard attached to UHCI

To: "Konstantin Baydarov" <kbaidarov@xxxxxxxxxxxxx>
Subject: Re: [PATCH] Add support for USB Keyboard attached to UHCI
From: "jidong xiao" <jidong.xiao@xxxxxxxxx>
Date: Wed, 28 Nov 2007 18:25:04 +0800
Cc: "Aaron Young" <ayoung@xxxxxxxxxxxxxxxxxxxx>, "Jay Lan" <jlan@xxxxxxx>, kdb@xxxxxxxxxxx
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=WY8goAsIeB343rosL9HiQp97T4GSgS67uUcx+f82x6w=; b=jm8++NiiXScer5agePafQ+p4ij63NUSJm83D8uDZaGWg9d30jqFrcbnPH2AKdZNUfDZIFljIlN2jF7/nE0MFXVvo/qIlhK6QeBP00Pn35H9uSZkMbQb82eQm6Y3Em6FaY76fHKUzCMpqU1zsw2a5nfqg1GOksr+82eE7LUPd9IM=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=NyNm7Sy7YHyhm81j9ZPXFGFStCLi//3gAQW1uvJOH7ApjvEzQ071TLMYdPs00juM4xYYQYlUL5sb+ekN64M03cH842rnCgqXt6BsGLvmKyOj9vTMcRy2ZDOA4ufVZkcfO33oIYzRA4tGjQLdUa/IXHf7szKJv9IjkqJkgrxyL9Y=
In-reply-to: <20071121150150.01b5d24d@xxxxxxxxxxxxxxxxxxxxx>
References: <20071105211716.14674612@medved> <200711051854.lA5Isg1n4205041@xxxxxxxxxxxxxxxxxx> <20071107171137.792d0304@xxxxxxxxxxxxxxxxxxxxx> <20071121150150.01b5d24d@xxxxxxxxxxxxxxxxxxxxx>
Sender: kdb-bounce@xxxxxxxxxxx
On Nov 21, 2007 8:01 PM, Konstantin Baydarov <kbaidarov@xxxxxxxxxxxxx> wrote:
>
> On Wed, 7 Nov 2007 17:11:37 +0300
> Konstantin Baydarov <kbaidarov@xxxxxxxxxxxxx> wrote:
>
> > On Mon, 5 Nov 2007 10:54:42 -0800 (PST)
> > Aaron Young <ayoung@xxxxxxxxxxxxxxxxxxxx> wrote:
> >
> > >   I've only dealt with OHCI driver code before, so I'm not qualified
> > > to review the UHCI specific code for you. As you say, it looks like
> > > a lot of your infastructure code introduces new globals
> > > (kdb_hcd_type) and uses kdb_usb_infos a lot - which is going away
> > > with my new implementation.
> > >
> > >   Would it be possible for you to wait for my new kdb/usb
> > > infastructure code and re-implement your UHCI code against it at
> > > that time? I could attempt to take an in depth look at it at that
> > > time perhaps...
> > >
> > >   Thanks,
> > >
> > >   -Aaron
> >
> >   Yes I'll intergrate UCHI code to the new KDB.
> > ---------------------------
> > Use http://oss.sgi.com/ecartis to modify your settings or to
> > unsubscribe.
>
>  UCHI support integrated to kdb-v4.4-2.6.24-rc2. Tested on i386 UP PC.
>
> Changes in USB interface:
>  - kdb_usb_uhci_keyboard_attach() to manage UHCI Keyboards
>  - kdb_uhci_submit_urb() is called by kdb_usb_uhci_keyboard_attach(). UHCI 
> KDB doesn't use HID urb, special urb with same parameters is used.
>  - void (*kdb_completion)(struct urb *urb); was added to hc_driver structure 
> to allow KDB UHCI driver reactivate KDB queue head.
>
> Known Issues of KDB driver:
>  - Autoreply of pressed key doesn't work
>  - When kernel enters KDB first pressed key doesn't appear on KDB
> console, because it's caught by UHCI kernel driver.
>  - Keyboard hotplug wasn't tested.
>  - Only 1 UHCI keyboard supported.
>
>  Jay, it looks you are using spaces instead of tabs or your mail client 
> replaces tabs with spaces, now(after USB patches) we have mixed code style. I 
> think cleanup should be done.
>
> Signed-off-by: Konstantin Baydarov <kbaidarov@xxxxxxxxxxxxx>

>

Has anyone else applied this patch?I am facing errors while compiling
kernel with this patch.

localhost:/usr/src/linux-2.6.24-rc2 # make
...
...
...
  CC      arch/x86/lib/msr-on-cpu.o
  LD      arch/x86/lib/built-in.o
  CC      arch/x86/lib/bitops_32.o
  CC      arch/x86/lib/delay_32.o
  AS      arch/x86/lib/getuser_32.o
  CC      arch/x86/lib/memcpy_32.o
  AS      arch/x86/lib/putuser_32.o
  AS      arch/x86/lib/semaphore_32.o
  CC      arch/x86/lib/string_32.o
  CC      arch/x86/lib/usercopy_32.o
  AR      arch/x86/lib/lib.a
  GEN     .version
  CHK     include/linux/compile.h
  UPD     include/linux/compile.h
  CC      init/version.o
  LD      init/built-in.o
  LD      .tmp_vmlinux1
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xee4): undefined reference to `usb_buffer_alloc'
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xf01): undefined reference to `usb_alloc_urb'
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xf70): undefined reference to `usb_submit_urb'
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xfb3): undefined reference to `usb_buffer_free'
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xfc5): undefined reference to `usb_free_urb'
make: *** [.tmp_vmlinux1] Error 1
localhost:/usr/src/linux-2.6.24-rc2 # make
  CHK     include/linux/version.h
  CHK     include/linux/utsrelease.h
  CALL    scripts/checksyscalls.sh
  CHK     include/linux/compile.h
  GEN     .version
  CHK     include/linux/compile.h
  UPD     include/linux/compile.h
  CC      init/version.o
  LD      init/built-in.o
  LD      .tmp_vmlinux1
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xee4): undefined reference to `usb_buffer_alloc'
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xf01): undefined reference to `usb_alloc_urb'
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xf70): undefined reference to `usb_submit_urb'
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xfb3): undefined reference to `usb_buffer_free'
arch/x86/kdb/built-in.o: In function `kdb_usb_uhci_keyboard_attach':
(.text+0xfc5): undefined reference to `usb_free_urb'
make: *** [.tmp_vmlinux1] Error 1

This is quite strange, as I see usb_buffer_alloc is declared in
<linux/usb.h>,and kdba_io_32.c includes <linux/kdb.h> which then
includes <linux/usb.h>. I am sure CONFIG_KDB_USB is enabled. So I am
now frustrated with this issue.

Regards
Jason
---------------------------
Use http://oss.sgi.com/ecartis to modify your settings or to unsubscribe.
<Prev in Thread] Current Thread [Next in Thread>