2008-04-09 20:35:35     ISP1761onBF561/uba

Document created by Aaronwu Employee on Aug 6, 2013
Version 1Show Document
  • View in full screen mode

2008-04-09 20:35:35     ISP1761onBF561/uba

sima sima (UNITED STATES)

Message: 53950   

 

Hi everyone

 

I am porting the isp1761 host driver on 2007R2 kernel version 2.6.22.15  for panview 2.1  on my ezkit-561

The ISP1761 chip on my board is wired up to the blackfin with 32-bit data bus.

when bootup ,I insmod the module as following:

 

root:~> modprobe usbcore

usbcore: registered new interface driver usbfs

usbcore: registered new interface driver hub

usbcore: registered new device driver usb

root:~> insmod bfin-isp1761.ko

root:~> insmod hal_pxa.ko

/home/videophone/isp1761hc-2.0.0.0-bfin/pehcd/hal/hal_pxa.c: pid 8210, vid 0015

 

/home/videophone/isp1761hc-2.0.0.0-bfin/pehcd/hal/hal_pxa.c: controller address

030ea034

 

root:~> insmod pehci.ko

/home/videophone/isp1761hc-2.0.0.0-bfin/pehcd/hal/hal_pxa.c: isp1761_register_dr

iver(drv=03193794)

 

isp1761 isp1761.0: PHILIPS ISP1761

isp1761 isp1761.0: new USB bus registered, assigned bus number 1

isp1761 isp1761.0: irq 87, io mem 0x00000000

usb usb1: Product: PHILIPS ISP1761

usb usb1: Manufacturer: Linux 2.6.22.15-ADI-2007R2-pre-svn Philips

usb usb1: SerialNumber: platform

usb usb1: configuration #1 chosen from 1 choice

hub 1-0:1.0: USB hub found

hub 1-0:1.0: 1 port detected

/home/videophone/isp1761hc-2.0.0.0-bfin/pehcd/hal/hal_pxa.c: Registered Driver P

hilips

/home/videophone/isp1761hc-2.0.0.0-bfin/pehcd/host/pehci.c: Host Driver has been

Registered

root:~> usb 1-1: new high speed USB device using isp1761 and address 2

usb 1-1: Product: ISP1520

usb 1-1: Manufacturer: Philips Semiconductors

usb 1-1: configuration #1 chosen from 1 choice

hub 1-1:1.0: USB hub found

hub 1-1:1.0: 3 ports detected

 

when I plug in a USB device and I get the following:

 

usb 1-1.2: new high speed USB device using isp1761 and address 3

usb 1-1.2: Product: Mass Storage

usb 1-1.2: Manufacturer: Generic

usb 1-1.2: SerialNumber: A69E4EFF

usb 1-1.2: configuration #1 chosen from 1 choice

uba: unknown partition table

 

I had add the uba in the device_table-min.txt,and I can find uba in /dev/

 

after plug the USB device ,i can find uba in /sys/block.

 

what's wrong here?

I have been working on this for servel days and I am out of ideas now.

 

-Thanks

QuoteReplyEditDelete

 

 

2008-04-10 04:23:46     Re: ISP1761onBF561/uba

Michael Hennerich (GERMANY)

Message: 54017    Hi Sima,

 

I can't remember we did a 2007R2 Release - can you use the 2008R1Release branch from svn?

Also the ISP1760 driver used to be hardcoded for 16-bit buses - I guess you spend some work on makeing it work on 32-bit buses?

 

Some time ago I fixed a bug related to only BF561 and USB Mass Storage - can you make sure that your version of arch/blackfin/setup.c only registers one cpu?

 

--- branches/2007R1/arch/blackfin/kernel/setup.c    2007/06/06 16:22:51    3269

+++ branches/2007R1/arch/blackfin/kernel/setup.c    2008/02/08 06:27:49    4237

@@ -427,20 +427,11 @@

            != ATOMIC_XOR32 - FIXED_CODE_START);

}

 

-#if defined(CONFIG_BF561)

-static struct cpu cpu[2];

-#else

+

static struct cpu cpu[1];

-#endif

static int __init topology_init(void)

{

-#if defined (CONFIG_BF561)

-    register_cpu(&cpu[0], 0);

-    register_cpu(&cpu[1], 1);

-    return 0;

-#else

     return register_cpu(cpu, 0);

-#endif

}

 

subsys_initcall(topology_init);

 

I never saw uba: - usually you should get sda1 etc.

Are you sure that you enable SCSI and SCSI-DISK support?

 

Please consult our Documentation Wiki and search for USB Mass Storage Support.

 

Best regards,

Michael

QuoteReplyEditDelete

 

 

2008-04-10 22:29:41     Re: ISP1761onBF561/uba

sima sima (UNITED STATES)

Message: 54062   

 

Thanks for your reply

 

I  think my uclinux kernel version is 2007R2 ,as following:

 

root:~> version

kernel:    Linux release 2.6.22.15-ADI-2007R2-pre-svn, build #448 Fri Apr 11 09:

26:02 CST 2008

toolchain: bfin-uclinux-gcc release gcc version 4.1.2 (ADI svn)

user-dist: release svn-9, build #411 Fri Apr 11 09:27:07 CST 2008

root:~

 

I think it works ok on 32-bit buses ,because i can  write and read registers about ISP1761 correctly.

 

I can mount uba under /mnt and can read and write correctly also.

 

>>I never saw uba: - usually you should get sda1 etc.

 

YES,I think so,but i get this surely, in menuconfig I enable this :

 

Device Drivers  --->  Device Drivers  --->  <*> Low Performance USB Block driver

 

IN linux-2.6.x\drivers\block\ub.c  I see the uba in ub_probe_lun (line 2306)

 

IN this case ,if i plug the USB device for servel times ,i can get the message an following:

 

usb 1-1.2: new high speed USB device using isp1761 and address 3          //(add 1 every time)

usb 1-1.2: Product: Mass Storage

usb 1-1.2: Manufacturer: Generic

usb 1-1.2: SerialNumber: A69E4EFF

usb 1-1.2: configuration #1 chosen from 1 choice

uba: unknown partition table

 

i can find uba in /sys/block and cat /proc/partitions ,I can find this block (180     0    1015808 uba0)

 

but if disable the Device Drivers  --->  Device Drivers  --->  < > Low Performance USB Block driver

 

first time ,i plug a USB device ,and can get as following:

 

usb 1-1.2: new high speed USB device using isp1761 and address 3

usb 1-1.2: configuration #1 chosen from 1 choice

scsi0 : SCSI emulation for USB Mass Storage devices

 

but i can't find noting about USB like sda in /sys/block,and cat /proc/partitions,there is no blocks about usb

 

next time ,i plug a USB device ,I can't get any message,it can't probe the USB device.

 

>>>Are you sure that you enable SCSI and SCSI-DISK support?

 

YES,i am sure i enable them.

 

 

 

 

 

 

 

 

 

 

 

 

 

QuoteReplyEditDelete

 

 

2008-04-11 08:48:59     Re: ISP1761onBF561/uba

Michael Hennerich (GERMANY)

Message: 54088    update your kernel to 2008R1 - or

 

you make sure that your version of arch/blackfin/setup.c only registers one cpu!

 

--- branches/2007R1/arch/blackfin/kernel/setup.c    2007/06/06 16:22:51    3269

+++ branches/2007R1/arch/blackfin/kernel/setup.c    2008/02/08 06:27:49    4237

@@ -427,20 +427,11 @@

            != ATOMIC_XOR32 - FIXED_CODE_START);

}

 

-#if defined(CONFIG_BF561)

-static struct cpu cpu[2];

-#else

+

static struct cpu cpu[1];

-#endif

static int __init topology_init(void)

{

-#if defined (CONFIG_BF561)

-    register_cpu(&cpu[0], 0);

-    register_cpu(&cpu[1], 1);

-    return 0;

-#else

     return register_cpu(cpu, 0);

-#endif

}

 

subsys_initcall(topology_init);

Attachments

    Outcomes