Panel-Card with kernel Linux-2.6.29 - problem with USB Mass Storage

Hi

At the begining I have question:
Does anybody have the files "panelcard_defconfig" and "board-panelcard.c" that are suitable for Linux-2.6.29 or Linux-2.6.27?
(I have created these files by myself but not everyfings works fine).

I am tring to run Panel-Card module with Linux-2.6.29 (or Linux-2.6.27).
I have copied files "panelcard_defconfig" and "board-panelcard.c" to the soures of Linux-2.6.29,
then I have modified these files and finally I have compiled the kernel:
...
# ARCH=arm CROSS_COMPILE=arm-linux-3.4.2- make zImage
...
...
OBJCOPY arch/arm/boot/zImage
Kernel: arch/arm/boot/zImage is ready
# ./mkimage -A arm -T kernel -O linux -C none -a 21000000 -e 21000000 -n plinux -d arch/arm/boot/zImage uImage
Image Name: plinux
Created: Mon Jul 13 13:31:12 2009
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 1414568 Bytes = 1381.41 kB = 1.35 MB
Load Address: 0x21000000
Entry Point: 0x21000000

My Panel-Card works fine with Linux-2.6.29 but I have got one problem:
I cann't mount my USB Mass Storage device:

U-Boot 1.1.4 (Jul 10 2009 - 08:39:47)

U-Boot code: 23F00000 -> 23F33A34 BSS: -> 23F78B28
RAM Configuration:
Bank #0: 20000000 32 MB
Manufacturer: AMD (Spansion) (227e)
Chip: AMD MIRROR S29GL512N 512Mbit 128kB Sectors
Unknown Chip: (4a04)
Flash: 64 MB
LCD: ET035005DM6
In: serial
Out: serial
Err: serial
U-Boot ver.1.1.4 Hit any key to stop autoboot: 3 \0x08\0x08\0x08 0
Copy to RAM...done
## Booting image at 10060000 ...
Image Name: plinux
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 1414568 Bytes = 1.3 MB
Load Address: 21000000
Entry Point: 21000000
Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux............................................................................................ done, booting the kernel.
Linux version 2.6.29 (root@adamr) (gcc version 3.4.2) #14 Mon Jul 13 11:19:09 CEST 2009
CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=00053177
CPU: VIVT data cache, VIVT instruction cache
Machine: taskit Panel-Card
Ignoring unrecognised tag 0x54410008
Memory policy: ECC disabled, Data cache writeback
Clocks: PLLA overclocked, 239 MHz
Clocks: CPU 239 MHz, master 119 MHz, main 18.432 MHz
Built 1 zonelists in Zone order, mobility grouping on. Total pages: 8128
Kernel command line: console=ttyS0,115200 mem=32M root=/dev/ram rw mtdparts=physmap-flash.0:384k(boot),1664k(linux),3072k(initrd),10240k(cfg),-(custom) initrd=0x21400000,0x300000
AT91: 96 gpio irqs in 3 banks
PID hash table entries: 128 (order: 7, 512 bytes)
Console: colour dummy device 80x30
Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
Memory: 32MB = 32MB total
Memory: 26440KB available (2588K code, 223K data, 112K init)
Calibrating delay loop... 119.60 BogoMIPS (lpj=598016)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
AT91: No default serial console defined.
AT91: Power Management (with slow clock mode)
AT91: Starting after general reset
bio: create slab at 0
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
musb_hdrc: version 6.0, pio, host, debug=0
checking if image is initramfs...it isn't (no cpio magic); looks like an initrd
Freeing initrd memory: 3072K
NetWinder Floating Point Emulator V0.97 (double precision)
JFFS2 version 2.2. (NAND) \0xc2\0xa9 2001-2006 Red Hat, Inc.
msgmni has been set to 57
alg: No test for stdrng (krng)
io scheduler noop registered
io scheduler anticipatory registered (default)
atmel_lcdfb atmel_lcdfb.0: 225KiB frame buffer at 21480000 (mapped at ffc00000)
atmel_lcdfb atmel_lcdfb.0: fb0: Atmel LCDC at 0x00600000 (mapped at c2866000), irq 21
atmel_usart.0: ttyS0 at MMIO 0xfefff200 (irq = 1) is a ATMEL_SERIAL
console [ttyS0] enabled
brd: module loaded
loop: module loaded
ssc ssc.1: Atmel SSC device at 0xc2870000 (irq 15)
Driver 'sd' needs updating - please use bus_type methods
physmap platform flash device: 04000000 at 10000000
physmap-flash.0: Found 1 x16 devices at 0x0 in 16-bit bank
Amd/Fujitsu Extended Query Table at 0x0040
physmap-flash.0: CFI does not contain boot bank location. Assuming top.
number of CFI chips: 1
cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.
5 cmdlinepart partitions found on MTD device physmap-flash.0
Creating 5 MTD partitions on "physmap-flash.0":
0x000000000000-0x000000060000 : "boot"
0x000000060000-0x000000200000 : "linux"
0x000000200000-0x000000500000 : "initrd"
0x000000500000-0x000000f00000 : "cfg"
0x000000f00000-0x000004000000 : "custom"
atmel_spi atmel_spi.0: Atmel SPI Controller at 0xfffc8000 (irq 12)
usbcore: registered new interface driver hwa-rc
116x: driver isp116x-hcd, 03 Nov 2005
ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
at91_ohci at91_ohci: AT91 OHCI
at91_ohci at91_ohci: new USB bus registered, assigned bus number 1
at91_ohci at91_ohci: irq 20, io mem 0x00500000
usb usb1: New USB device found, idVendor=1d6b, idProduct=0001
usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
usb usb1: Product: AT91 OHCI
usb usb1: Manufacturer: Linux 2.6.29 ohci_hcd
usb usb1: SerialNumber: at91
usb usb1: configuration #1 chosen from 1 choice
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 2 ports detected
sl811: driver sl811-hcd, 19 May 2005
r8a66597_hcd: driver r8a66597_hcd, 10 Apr 2008
usbcore: registered new interface driver hwa-hc
usbcore: registered new interface driver wusb-cbaf
usbcore: registered new interface driver cdc_acm
cdc_acm: v0.26:USB Abstract Control Model driver for USB modems and ISDN adapters
usbcore: registered new interface driver usbtmc
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
usbcore: registered new interface driver libusual
usbcore: registered new interface driver usbserial
usbserial: USB Serial Driver core
usbcore: registered new interface driver usbtest
udc: at91_udc version 3 May 2006
mice: PS/2 mouse device common for all mice
i2c /dev entries driver
i2c-gpio i2c-gpio: using pins 39 (SDA) and 40 (SCL)
Driver for 1-wire Dallas network protocol.
Advanced Linux Sound Architecture Driver Version 1.0.18a.
at73c213 spi0.3: at73c213: supported bitrate is 29250 (128 divider)
ALSA device list:
#0: AT91SAM9261-EK external DAC on irq 15
drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
RAMDISK: Compressed image found at block 0
VFS: Mounted root (ext2 filesystem) on device 1:0.
Freeing init memory: 112K
Warning: unable to open an initial console.

(none) login: root
Password:
login: can't chdir to home directory '/root'
login[892]: root login on 'ttyS0'
# mkdir /dr
# usb 1-1: new full speed USB device using at91_ohci and address 2
usb 1-1: New USB device found, idVendor=0951, idProduct=1603
usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-1: Product: DataTraveler 2.0
usb 1-1: Manufacturer: Kingston
usb 1-1: SerialNumber: 899000000000000000000159
usb 1-1: configuration #1 chosen from 1 choice
scsi0 : SCSI emulation for USB Mass Storage devices
scsi 0:0:0:0: Direct-Access Kingston DataTraveler 2.0 1.00 PQ: 0 ANSI: 2
sd 0:0:0:0: [sda] 3928064 512-byte hardware sectors: (2.01 GB/1.87 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Assuming drive cache: write through
sd 0:0:0:0: [sda] 3928064 512-byte hardware sectors: (2.01 GB/1.87 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Assuming drive cache: write through
sda:<7>usb-storage: queuecommand called
sda1
sd 0:0:0:0: [sda] Attached SCSI removable disk

# mount /dev/sda1 /dr
mount: mounting /dev/sda1 on /dr failed: No such file or directory

# ls -l /dev/sda1
ls: /dev/sda1: No such file or directory

#cat /proc/partitions
major minor #blocks name

31 0 384 mtdblock0
31 1 1664 mtdblock1
31 2 3072 mtdblock2
31 3 10240 mtdblock3
31 4 50176 mtdblock4
8 0 1964032 sda
8 1 1963908 sda1

# df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/root 15491 5810 9681 38% /
/dev/mtdblock3 10240 1612 8628 16% /config

# pwd
/sys/block/sda/sda1

# ls -l
-r--r--r-- 1 root root 4096 Jan 1 01:03 mdev
drwxr-xr-x 2 root root 0 Jan 1 01:03 holders
-r--r--r-- 1 root root 4096 Jan 1 01:03 partition
drwxr-xr-x 2 root root 0 Jan 1 01:03 power
-r--r--r-- 1 root root 4096 Jan 1 01:03 size
-r--r--r-- 1 root root 4096 Jan 1 01:03 mstart
-r--r--r-- 1 root root 4096 Jan 1 01:03 mstat
lrwxrwxrwx 1 root root 0 Jan 1 01:03 subsystem -> ../../../block
-rw-r--r-- 1 root root 4096 Jan 1 01:03 uevent

# cat uevent
MAJOR=8
MINOR=1
DEVTYPE=partition
PHYSDEVPATH=/devices/platform/at91_ohci/usb1/1-1/1-1:1.0/host0/target0:0:0/0:0:0:0
PHYSDEVBUS=scsi
PHYSDEVDRIVER=sd

AttachmentSize
conf_files.zip11.86 KB

Re: Panel-Card with kernel Linux-2.6.29 - problem with USB ...

It looks like it is more a problem of your ramdisk and not the kernel.

Warning: unable to open an initial console.

The above message indicates, that your rootfs is missing some files in /dev. There should be at least: null, console, ttyS0, fd as a symlink to /proc/self/fd, stdin, stdout and stderr as symlinks to fd/0, fd/1 and fd/2 and the directory pts.

This might be the reason, why mdev does not work correctly and therefore does not create the device files. But you can still test the functionality of USB mass storage by creating the device file manually:

mknod /dev/sda1 b 8 1

Now it should be mountable.

Or is the mdev start missing in the init scripts?

Re: Panel-Card with kernel Linux-2.6.29 - problem with USB ...

You are right.
After creating the device file (mknod /dev/sda1 b 8 1) I can mount my USB Mass Storage Drive.
USB Mass Storage works fine.

I think, I have to repair my root file system.

Thanks

Syndicate content