Intel x86单片机开发板usb驱动如何更改SPI驱动

1 Pages: 1/2& & &Go
主题 : 请教下SPI驱动 加载的问题
专注与嵌入式linux的图像,视频方向的开发。
级别: 侠客
金钱: 405 两
威望: 81 点
贡献值: 0 点
综合积分: 162 分
&请教下SPI驱动 加载的问题
大家好,&&我的板子是MINI6410&&NAND:256M,DDR 256M&&LCD :H43按照 的步骤,做了如下操作:步骤1 增加头文件
#include &linux/spi/spidev.h&#include &linux/spi/spi.h&#include &plat/s3c64xx-spi.h&&& 步骤2 配置内核选项Device Drivers&&---& [*] SPI support&&---& &M&&& Samsung S3C24XX series SPI&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& &M&&& User mode SPI device driver support&&&&&& 步骤三: && 增加 &s3c64xx_device_spi0, 到 ---&&& [static struct platform_device *mini6410_devices[]] 的末尾&&&&&& 增加 add [obj-y&&&&&& +=dev-spi.o] 到 arch/arm/mach-s3c64xx/Makefile&& 在头文件语句的下面增加&& &&&& static void&&cs_set_level(unsigned line_id, int lvl) {&&&&gpio_direction_output(line_id, lvl);};static struct s3c64xx_spi_csinfo s3c64xx_spi0_csinfo = {&&.fb_delay=100,&&.line=S3C64XX_GPC(3),&&.set_level=cs_set_level,};static struct spi_board_info s3c6410_spi0_board[] = { [0] = { .modalias = &spidev&, .bus_num= 0, .chip_select= 0, //必须小于s3c6410_spi0_platdata.num_cs .irq =IRQ_SPI0, .max_speed_hz= 500*1000, .mode=SPI_MODE_0,.controller_data=&s3c64xx_spi0_csinfo,}, }; 在mini6410_machine_init(before platform_add_devices)中增加[ s3c64xx_spi_set_info(0,0,1);&& //gzj++&&&&&& //s3c64xx_spi_set_info(1,0,1);&&&&&& spi_register_board_info(s3c6410_spi0_board, ARRAY_SIZE(s3c6410_spi0_board)); &&&& // spi_register_board_info(s3c6410_spi1_board, ARRAY_SIZE(s3c6410_spi1_board)); &&]&&&& 步骤四:&&&&&&&&do make zImage&&&&&&&&do make 然后再6410的板子上执行:&&&&&&&&&&&& insmod spi_s3c64xx.ko&& &&&&&&&&&&&& insmod spidev.ko&&&&&&&&&&&&&& &&&&&&&&&&&& &&&&&&&&&&&& 结果打印的信息是这样的:&&&&&&&&&&&& [root@FriendlyARM plg]# insmod spi_s3c64xx.ko:99 gpio_ensure_requested+0x48/0xf4()autorequest GPIO-20Modules linked in: spi_s3c64xx(+)[&c0173c44&] (unwind_backtrace+0x0/0xe4) from [&c0182ea0&] (warn_slowpath_common+0x4c/0x64)[&c0182ea0&] (warn_slowpath_common+0x4c/0x64) from [&c0182f38&] (warn_slowpath_fmt+0x2c/0x3c)[&c0182f38&] (warn_slowpath_fmt+0x2c/0x3c) from [&c02df5ac&] (gpio_ensure_requested+0x48/0xf4)[&c02df5ac&] (gpio_ensure_requested+0x48/0xf4) from [&c02df79c&] (gpio_direction_output+0x68/0x120)[&c02df79c&] (gpio_direction_output+0x68/0x120) from [&bf00061c&] (s3c64xx_spi_setup+0x1f4/0x210 [spi_s3c64xx])[&bf00061c&] (s3c64xx_spi_setup+0x1f4/0x210 [spi_s3c64xx]) from [&c0330914&] (spi_setup+0x40/0x48)[&c0330914&] (spi_setup+0x40/0x48) from [&c0330b9c&] (spi_add_device+0xa0/0x118)[&c0330b9c&] (spi_add_device+0xa0/0x118) from [&c0330c94&] (spi_new_device+0x80/0xa4)[&c0330c94&] (spi_new_device+0x80/0xa4) from [&c0330cd8&] (spi_match_master_to_boardinfo+0x20/0x40)[&c0330cd8&] (spi_match_master_to_boardinfo+0x20/0x40) from [&c0330dcc&] (spi_register_master+0xd4/0x118)[&c0330dcc&] (spi_register_master+0xd4/0x118) from [&bf0043d4&] (s3c64xx_spi_probe+0x3d4/0x4a8 [spi_s3c64xx])[&bf0043d4&] (s3c64xx_spi_probe+0x3d4/0x4a8 [spi_s3c64xx]) from [&c0300b40&] (platform_drv_probe+0x14/0x18)[&c0300b40&] (platform_drv_probe+0x14/0x18) from [&c02ffd34&] (driver_probe_device+0xa8/0x158)[&c02ffd34&] (driver_probe_device+0xa8/0x158) from [&c02ffe44&] (__driver_attach+0x60/0x84)[&c02ffe44&] (__driver_attach+0x60/0x84) from [&c02ff01c&] (bus_for_each_dev+0x4c/0x78)[&c02ff01c&] (bus_for_each_dev+0x4c/0x78) from [&c02ff6b8&] (bus_add_driver+0xa8/0x224)[&c02ff6b8&] (bus_add_driver+0xa8/0x224) from [&c0300090&] (driver_register+0xa8/0x12c)[&c0300090&] (driver_register+0xa8/0x12c) from [&c0300da4&] (platform_driver_probe+0x18/0x8c)[&c0300da4&] (platform_driver_probe+0x18/0x8c) from [&c01644d8&] (do_one_initcall+0xbc/0x190)[&c01644d8&] (do_one_initcall+0xbc/0x190) from [&c01aa098&] (sys_init_module+0x158c/0x1754)[&c01aa098&] (sys_init_module+0x158c/0x1754) from [&c016e5e0&] (ret_fast_syscall+0x0/0x30)---[ end trace fcc177dd ]---请教一下这样的操作过后,可以在/dev下生成对应的spidev0.0这个设备,spi也可以首发,但是问题是: 当接收大概4--8个包以后,就不再接收 了,就是说我应用层读不来了。
专注与嵌入式linux的图像,视频方向的开发。
级别: 侠客
金钱: 405 两
威望: 81 点
贡献值: 0 点
综合积分: 162 分
从给板子上电,到 insmod 后出现错误的打印信息,如下:NR_IRQS:246VIC @f6000000: id 0x, vendor 0x41VIC @f6010000: id 0x, vendor 0x41Console: colour dummy device 80x30console [ttySAC0] enabledCalibrating delay loop... 530.84 BogoMIPS (lpj=2654208)pid_max: default: 32768 minimum: 301Mount-cache hash table entries: 512CPU: Testing write buffer coherency: okNET: Registered protocol family 16s3c64xx_dma_init: Registering DMA channelsPL080: IRQ 73, at d0808000, channels 0..8PL080: IRQ 74, at d080c000, channels 8..16S3C6410: Initialising architecturebio: create slab &bio-0& at 0SCSI subsystem initializedusbcore: registered new interface driver usbfsusbcore: registered new interface driver hubusbcore: registered new device driver usbs3c-i2c s3c2440-i2c: slave address 0x10s3c-i2c s3c2440-i2c: bus frequency set to 64 KHzs3c-i2c s3c2440-i2c: i2c-0: S3C I2C adapterAdvanced Linux Sound Architecture Driver Version 1.0.23.NET: Registered protocol family 2IP route cache hash table entries: 2048 (order: 1, 8192 bytes)TCP established hash table entries: 8192 (order: 4, 65536 bytes)TCP bind hash table entries: 8192 (order: 5, 163840 bytes)TCP: Hash tables configured (established 8192 bind 8192)TCP reno registeredUDP hash table entries: 128 (order: 0, 6144 bytes)UDP-Lite hash table entries: 128 (order: 0, 6144 bytes)NET: Registered protocol family 1RPC: Registered udp transport module.RPC: Registered tcp transport module.RPC: Registered tcp NFSv4.1 backchannel transport module.NetWinder Floating Point Emulator V0.97 (double precision)squashfs: version 4.0 () Phillip Loughermsgmni has been set to 420io scheduler noop registered (default)io scheduler cfq registeredS3C_LCD clock got enabled :: 133.000 MhzLCD TYPE :: H43 will be initializedWindow[0] - FB1: map_video_memory: clear ff7f800&&&&&&&&&&&&FB1: map_video_memory: dma=5d780000 cpu=ff000000 size=Window[0] - FB2: map_video_memory: clear ff03fc00:0003fc00&&&&&&&&&&&&FB2: map_video_memory: dma=5d7bfc00 cpu=ff03fc00 size=0003fc00Console: switching to colour frame buffer device 60x34fb0: s3cfb frame buffer deviceWindow[1] - FB1: map_video_memory: clear ff7f800&&&&&&&&&&&&FB1: map_video_memory: dma=5cc00000 cpu=ff080000 size=Window[1] - FB2: map_video_memory: clear ff0bfc00:0003fc00&&&&&&&&&&&&FB2: map_video_memory: dma=5cc3fc00 cpu=ff0bfc00 size=0003fc00fb1: s3cfb frame buffer deviceWindow[2] - FB1: map_video_memory: clear ff3fc00&&&&&&&&&&&&FB1: map_video_memory: dma=5d740000 cpu=ff100000 size=0003fc00fb2: s3cfb frame buffer deviceWindow[3] - FB1: map_video_memory: clear ff3fc00&&&&&&&&&&&&FB1: map_video_memory: dma=5cc80000 cpu=ff140000 size=0003fc00fb3: s3cfb frame buffer devicebacklight&&&&&& initializeds3c6400-uart.0: ttySAC0 at MMIO 0x7f005000 (irq = 16) is a S3C6400/10s3c6400-uart.1: ttySAC1 at MMIO 0x7f005400 (irq = 20) is a S3C6400/10s3c6400-uart.2: ttySAC2 at MMIO 0x7f005800 (irq = 24) is a S3C6400/10s3c6400-uart.3: ttySAC3 at MMIO 0x7f005c00 (irq = 28) is a S3C6400/10leds&&&&initializedbuttons initializedpwm&&&& initializedadc&&&& initializedloop: module loadedS3C NAND Driver, (c) 2008 Samsung ElectronicsS3C NAND Driver is using hardware ECC.NAND device: Manufacturer ID: 0xec, Chip ID: 0xda (Samsung NAND 256MiB 3,3V 8-bit)Creating 3 MTD partitions on &NAND 256MiB 3,3V 8-bit&:0x-0x : &Bootloader&0x-0x : &Kernel&0x-0x : &File System&PPP generic driver version 2.4.2PPP Deflate Compression module registeredPPP BSD Compression module registeredPPP MPPE Compression module registeredNET: Registered protocol family 24dm9000 Ethernet Driver, V1.31eth0: dm9000a at d081e000,d0c00004 IRQ 108 MAC: 08:90:00:a0:90:90 (platform data)ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Drivers3c2410-ohci s3c2410-ohci: S3C24XX OHCIs3c2410-ohci s3c2410-ohci: new USB bus registered, assigned bus number 1s3c2410-ohci s3c2410-ohci: irq 79, io mem 0xusb usb1: New USB device found, idVendor=1d6b, idProduct=0001usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1usb usb1: Product: S3C24XX OHCIusb usb1: Manufacturer: Linux 2.6.38-FriendlyARM ohci_hcdusb usb1: SerialNumber: s3c24xxhub 1-0:1.0: USB hub foundhub 1-0:1.0: 2 ports detectedusbcore: registered new interface driver usbserialUSB Serial support registered for genericusbcore: registered new interface driver usbserial_genericusbserial: USB Serial Driver coreUSB Serial support registered for GSM modem (1-port)usbcore: registered new interface driver optionoption: v0.7.2:USB Driver for GSM modemsUSB Serial support registered for aircableusbcore: registered new interface driver aircableUSB Serial support registered for ark3116usbcore: registered new interface driver ark3116ark:USB ARK3116 serial/IrDA driverUSB Serial support registered for Belkin / Peracom / GoHubs USB Serial Adapterusbcore: registered new interface driver belkinbelkin_sa: v1.3:USB Belkin Serial converter driverUSB Serial support registered for ch341-uartusbcore: registered new interface driver ch341USB Serial support registered for cp210xusbcore: registered new interface driver cp210xcp210x: v0.09:Silicon Labs CP210x RS232 serial adaptor driverUSB Serial support registered for Reiner SCT Cyberjack USB card readerusbcore: registered new interface driver cyberjackcyberjack: v1.01 Matthias Bruestlecyberjack: REINER SCT cyberJack pinpad/e-com USB Chipcard Reader DriverUSB Serial support registered for DeLorme Earthmate USBUSB Serial support registered for HID-&COM RS232 AdapterUSB Serial support registered for Nokia CA-42 V2 Adapterusbcore: registered new interface driver cypresscypress_m8: v1.10:Cypress USB to Serial DriverUSB Serial support registered for debugusbcore: registered new interface driver debugUSB Serial support registered for Digi 2 port USB adapterUSB Serial support registered for Digi 4 port USB adapterusbcore: registered new interface driver digi_acceleportdigi_acceleport: v1.80.1.2:Digi AccelePort USB-2/USB-4 Serial Converter driverUSB Serial support registered for Edgeport 2 port adapterUSB Serial support registered for Edgeport 4 port adapterUSB Serial support registered for Edgeport 8 port adapterUSB Serial support registered for EPiC deviceusbcore: registered new interface driver io_edgeportio_edgeport: v2.7:Edgeport USB Serial DriverUSB Serial support registered for Edgeport TI 1 port adapterUSB Serial support registered for Edgeport TI 2 port adapterusbcore: registered new interface driver io_tiio_ti: v0.7mode043006:Edgeport USB Serial DriverUSB Serial support registered for empegusbcore: registered new interface driver empegempeg: v1.3:USB Empeg Mark I/II DriverUSB Serial support registered for FTDI USB Serial Deviceusbcore: registered new interface driver ftdi_sioftdi_sio: v1.6.0:USB FTDI Serial Converters DriverUSB Serial support registered for funsoftusbcore: registered new interface driver funsoftUSB Serial support registered for Garmin GPS usb/ttyusbcore: registered new interface driver garmin_gpsgarmin_gps: v0.33:garmin gps driverUSB Serial support registered for hp4Xusbcore: registered new interface driver hp4Xhp4x: v1.00:HP4x (48/49) Generic Serial driverUSB Serial support registered for PocketPC PDAusbcore: registered new interface driver ipaqipaq: v1.0:USB PocketPC PDA driverUSB Serial support registered for IPWireless converterusbcore: registered new interface driver ipwttyipw: v0.4:IPWireless tty driverUSB Serial support registered for IR Dongleusbcore: registered new interface driver ir-usbir_usb: v0.5:USB IR Dongle driverUSB Serial support registered for iuu_phoenixusbcore: registered new interface driver iuu_phoenixiuu_phoenix: v0.12:Infinity USB Unlimited Phoenix driverUSB Serial support registered for Keyspan - (without firmware)USB Serial support registered for Keyspan 1 port adapterUSB Serial support registered for Keyspan 2 port adapterUSB Serial support registered for Keyspan 4 port adapterusbcore: registered new interface driver keyspankeyspan: v1.1.5:Keyspan USB to Serial Converter DriverUSB Serial support registered for Keyspan PDAUSB Serial support registered for Keyspan PDA - (prerenumeration)USB Serial support registered for Xircom / Entregra PGS - (prerenumeration)usbcore: registered new interface driver keyspan_pdakeyspan_pda: v1.1:USB Keyspan PDA Converter driverUSB Serial support registered for KL5KUSB105D / PalmConnectusbcore: registered new interface driver kl5kusb105dkl5kusb105: v0.4:KLSI KL5KUSB105 chipset USB-&Serial Converter driverUSB Serial support registered for KOBIL USB smart card terminalusbcore: registered new interface driver kobilkobil_sct: 21/05/2004:KOBIL USB Smart Card Terminal Driver (experimental)USB Serial support registered for MCT U232usbcore: registered new interface driver mct_u232mct_u232: z2.1:Magic Control Technology USB-RS232 converter driverUSB Serial support registered for Moschip 2 port adaptermos:Moschip USB Serial Driverusbcore: registered new interface driver moschip7720USB Serial support registered for Moschip
USB Serial Drivermos.2:Moschip
USB Serial Driverusbcore: registered new interface driver mos7840USB Serial support registered for moto-modemusbcore: registered new interface driver moto-modemUSB Serial support registered for navmanusbcore: registered new interface driver navmanUSB Serial support registered for ZyXEL - omni.net lcd plus usbusbcore: registered new interface driver omninetomninet: v1.1:USB ZyXEL omni.net LCD PLUS DriverUSB Serial support registered for opticonusbcore: registered new interface driver opticonUSB Serial support registered for oti6858usbcore: registered new interface driver oti6858USB Serial support registered for pl2303usbcore: registered new interface driver pl2303pl2303: Prolific PL2303 USB to serial adaptor driverUSB Serial support registered for qcauxusbcore: registered new interface driver qcauxUSB Serial support registered for Qualcomm USB modemusbcore: registered new interface driver qcserialsafe_serial: v0.1:USB Safe Encapsulated SerialUSB Serial support registered for safe_serialusbcore: registered new interface driver safe_serialUSB Serial support registered for sam-bausbcore: registered new interface driver sam-basam_ba: v1.0: Atmel SAM Boot Assistant (SAM-BA) driverUSB Serial support registered for siemens_mpiusbcore: registered new interface driver siemens_mpiDriver for Siemens USB/MPI adapterVersion 0.1 09/26/2005 Thomas
USB Serial support registered for Sierra USB modemusbcore: registered new interface driver sierrasierra: v.1.7.16:USB Driver for Sierra Wireless USB modemsUSB Serial support registered for SPCP8x5usbcore: registered new interface driver spcp8x5spcp8x5: v0.10:SPCP8x5 USB to serial adaptor driverUSB Serial support registered for Quatech SSU-100 USB to Serial Driverusbcore: registered new interface driver ssu100ssu100: v0.1:Quatech SSU-100 USB to Serial DriverUSB Serial support registered for symbolusbcore: registered new interface driver symbolUSB Serial support registered for TI USB 3410 1 port adapterUSB Serial support registered for TI USB 5052 2 port adapterusbcore: registered new interface driver ti_usb_ti_usb_: v0.10:TI USB
Serial DriverUSB Serial support registered for Handspring Visor / Palm OSUSB Serial support registered for Sony Clie 3.5USB Serial support registered for Sony Clie 5.0usbcore: registered new interface driver visorvisor: USB HandSpring Visor / Palm OS driverUSB Serial support registered for Connect Tech - WhiteHEAT - (prerenumeration)USB Serial support registered for Connect Tech - WhiteHEATusbcore: registered new interface driver whiteheatwhiteheat: v2.0:USB ConnectTech WhiteHEAT driverUSB Serial support registered for vivopay-serialusbcore: registered new interface driver vivopay-serialvivopay_serial: v1.0:ViVOpay USB Serial DriverUSB Serial support registered for ziousbcore: registered new interface driver zioInitializing USB Mass Storage driver...usbcore: registered new interface driver usb-storageUSB Mass Storage support registered.s3c-hsotg s3c-hsotg: regs d0840000, irq 90s3c-hsotg s3c-hsotg: s3c_hsotg_corereset: reset failed, GRSTCTL=s3c-hsotg s3c-hsotg: GRXFSIZ=0x, GNPTXFSIZ=0xs3c-hsotg s3c-hsotg: shared fifoss3c-hsotg s3c-hsotg: cannot create debug roots3c-hsotg s3c-hsotg: DCFG=0x, DCTL=0x, DIEPMSK=0000000fs3c-hsotg s3c-hsotg: GAHBCFG=0xx44=0xs3c-hsotg s3c-hsotg: GRXFSIZ=0x, GNPTXFSIZ=0xs3c-hsotg s3c-hsotg: DPTx[1] FSize=768, StAddr=0x00000f00s3c-hsotg s3c-hsotg: DPTx[2] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: DPTx[3] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: DPTx[4] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: DPTx[5] FSize=768, StAddr=0x00001b00s3c-hsotg s3c-hsotg: DPTx[6] FSize=768, StAddr=0x00001e00s3c-hsotg s3c-hsotg: DPTx[7] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: DPTx[8] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: DPTx[9] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: DPTx[10] FSize=768, StAddr=0x00002a00s3c-hsotg s3c-hsotg: DPTx[11] FSize=768, StAddr=0x00002d00s3c-hsotg s3c-hsotg: DPTx[12] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: DPTx[13] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: DPTx[14] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: DPTx[15] FSize=768, StAddr=0xs3c-hsotg s3c-hsotg: ep0-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep0-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep1-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep1-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep2-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep2-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep3-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep3-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep4-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep4-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep5-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep5-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep6-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep6-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep7-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep7-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep8-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep8-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep9-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep9-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep10-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep10-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep11-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep11-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep12-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep12-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep13-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep13-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep14-in: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: ep14-out: EPCTL=0x, SIZ=0x, DMA=0xs3c-hsotg s3c-hsotg: DVBUSDIS=0x, DVBUSPULSE=mousedev: PS/2 mouse device common for all miceS3C Touchscreen driver, (c) 2010 FriendlyARMtouchscreen got loaded successfully : 12 bitstouchscreen-1wire&&&&&& initializedbacklight-1wire initializedinput: TouchScreen Pipe as /devices/virtual/input/input0ts-if&& initializedS3C24XX RTC, (c)
Simtec Electronicss3c-rtc s3c64xx-rtc: rtc disabled, re-enablings3c-rtc s3c64xx-rtc: rtc core: registered s3c as rtc0i2c /dev entries driverLinux video capture interface: v2.00i2c-core: driver [tuner] using legacy suspend methodi2c-core: driver [tuner] using legacy resume methodi2c-core: driver [msp3400] using legacy suspend methodi2c-core: driver [msp3400] using legacy resume methodusbcore: registered new interface driver usbvisionUSBVision USB Video Device Driver for Linux : 0.9.10usbcore: registered new interface driver pvrusb2pvrusb2: V4L in-tree version:Hauppauge WinTV-PVR-USB2 MPEG2 Encoder/Tunerpvrusb2: Debug mask is 31 (0x1f)usbcore: registered new interface driver zr364xxzr364xx: Zoran 364xxusbcore: registered new interface driver stkwebcamone_wire_status: 4pwc: Philips webcam module version 10.0.14 loaded.pwc: Supports Philips PCA645/646, PCVC675/680/690, PCVC720[40]/730/740/750 & PCVC830/840.pwc: Also supports the Askey VC010, various Logitech Quickcams, Samsung MPC-C10 and MPC-C30,one_wire_status: 4pwc: the Creative WebCam 5 & Pro Ex, SOTEC Afina Eye and Visionite VCS-UC300 and VCS-UM100.usbcore: registered new interface driver Philips webcamgspca: v2.12.0 registeredone_wire_status: 4usbcore: registered new interface driver benqusbcore: registered new interface driver conexusbcore: registered new interface driver cpia1usbcore: registered new interface driver etomsusbcore: registered new interface driver finepixusbcore: registered new interface driver jeilinjusbcore: registered new interface driver konicausbcore: registered new interface driver marsusbcore: registered new interface driver mr97310aone_wire_status: 4usbcore: registered new interface driver ov519usbcore: registered new interface driver ov534usbcore: registered new interface driver ov534_9usbcore: registered new interface driver pac207usbcore: registered new interface driver pac7302usbcore: registered new interface driver pac7311usbcore: registered new interface driver sn9c2028usbcore: registered new interface driver sn9c20xusbcore: registered new interface driver sonixbone_wire_status: 4usbcore: registered new interface driver sonixjusbcore: registered new interface driver spca500usbcore: registered new interface driver spca501usbcore: registered new interface driver spca505usbcore: registered new interface driver spca506spca506: registeredusbcore: registered new interface driver spca508usbcore: registered new interface driver spca561usbcore: registered new interface driver spca1528one_wire_status: 4usbcore: registered new interface driver sq905usbcore: registered new interface driver sq905cusbcore: registered new interface driver sq930xusbcore: registered new interface driver sunplususbcore: registered new interface driver stk014usbcore: registered new interface driver stv0680usbcore: registered new interface driver t613usbcore: registered new interface driver tv8532usbcore: registered new interface driver vc032xone_wire_status: 4usbcore: registered new interface driver xirlink-citusbcore: registered new interface driver zc3xxusbcore: registered new interface driver ALi m5602usbcore: registered new interface driver STV06xxgspca_gl860: driver startup - version 0.9d10usbcore: registered new interface driver gspca_gl860usbcore: registered new interface driver hdpvrusbcore: registered new interface driver s2255s3c-fimc: controller 0 registered successfullys3c-fimc: controller 1 registered successfullyFIMC Driver, 2010 ported by FriendlyARM ov965x: probes3c-fimc: i2c transfer errors3c-fimc: i2c transfer errors3c-fimc: i2c transfer errors3c-fimc: i2c transfer errorone_wire_status: 4s3c-fimc: ov965x: Product ID fb:fb Manufacturer ID fb:fbparent clock for camera: 266.000 MHz, divisor: 11[CAM]RESET CAM.S3C6400 MFC Driver, (c) 2007 Samsung Electronics, 2010 ported by FriendlyARM
S3C6400 MFC Driver init OK. S3C PostProcessor Driver v3.12, (c) 2009 Samsung ElectronicsS3C6410 TV encoder Driver, (c) 2008 Samsung Electronics S3C6410 TV encoder Driver init OK. S3C6410 TV scaler Driver, (c) 2008 Samsung Electronics S3C6410 TV scaler Driver init OK. S3C Rotator Driver, (c) 2008 Samsung Electronicss3c_rotator_probe calleds3c_rotator_probe successS3C JPEG Driver, (c) 2007 Samsung Electronicsone_wire_status: 4s3c_g2d_probe called s3c_g2d_probe Success S3C G2D Init : DoneS3C G3D Driver, (c)
Samsung Electronicss3c_g3d version : 0x1050000 S3C G3D Init : Doneusbcore: registered new interface driver uvcvideoUSB Video Class driver (v1.0.0)S3C2410 Watchdog Timer, (c) 2004 Simtec Electronicss3c2410-wdt s3c2410-wdt: watchdog inactive, reset disabled, irq enabledsdhci: Secure Digital Host Controller Interface driversdhci: Copyright(c) Pierre Ossmanone_wire_status: 4s3c-sdhci s3c-sdhci.0: clock source 0: hsmmc ( Hz)s3c-sdhci s3c-sdhci.0: clock source 1: hsmmc ( Hz)s3c-sdhci s3c-sdhci.0: clock source 2: mmc_bus ( Hz)mmc0: SDHCI controller on samsung-hsmmc [s3c-sdhci.0] using ADMAs3c-sdhci s3c-sdhci.1: clock source 0: hsmmc ( Hz)s3c-sdhci s3c-sdhci.1: clock source 1: hsmmc ( Hz)s3c-sdhci s3c-sdhci.1: clock source 2: mmc_bus ( Hz)one_wire_status: 4mmc1: SDHCI controller on samsung-hsmmc [s3c-sdhci.1] using ADMAusbcore: registered new interface driver usbhidusbhid: USB HID core drivermmc0: new high speed SDHC card at address 5b2ammcblk0: mmc0:5b2a SD04G 3.69 GiB
mmcblk0: p1asoc: wm9713-hifi &-& samsung-ac97 mapping okALSA device list:&&#0: MINI6410TCP cubic registeredNET: Registered protocol family 17VFP support v0.3: implementor 41 architecture 1 part 20 variant b rev 5s3c-rtc s3c64xx-rtc: setting system clock to
23:44:28 UTC ()Freeing init memory: 1412Kyaffs: dev is
name is &mtdblock2& rwyaffs: passed flags &&FAT: utf8 is not a recommended IO charset for FAT filesystems, filesystem will be case sensitive!fa_cpu_pfn: module license 'Proprietary' taints kernel.Disabling lock debugging due to kernel taintFriendlyARM proprietary driver for mini6410 initialized.[17/Jan/:38 +0000] boa: server version Boa/0.94.13[17/Jan/:38 +0000] boa: server built Dec 30 2010 at 11:18:35.[17/Jan/:38 +0000] boa: starting server pid=955, port 80&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&Try to bring eth0 interface up......eth0: link downDonePlease press Enter to activate this console. [root@FriendlyARM /]# lsbin&&&&&&&&&&&&&&&& lost+found&&&&&&&&&&sysdev&&&&&&&&&&&&&&&& mnt&&&&&&&&&&&&&&&& tmpetc&&&&&&&&&&&&&&&& opt&&&&&&&&&&&&&&&& udiskfa-network-service&&proc&&&&&&&&&&&&&&&&usrhome&&&&&&&&&&&&&&&&root&&&&&&&&&&&&&&&&varlib&&&&&&&&&&&&&&&& sbin&&&&&&&&&&&&&&&&wwwlinuxrc&&&&&&&&&&&& sdcard[root@FriendlyARM /]# cd /home/plg/[root@FriendlyARM plg]# ls[root@FriendlyARM plg]# cd ..[root@FriendlyARM /home]# lsplg&&&&&&&&&&&& spi_s3c64xx.ko&&spidev.ko[root@FriendlyARM /home]# insmod spidev.ko [root@FriendlyARM /home]# insmod spi_s3c64xx.ko ------------[ cut here ]------------WARNING: at drivers/gpio/gpiolib.c:99 gpio_ensure_requested+0x48/0xf4()autorequest GPIO-20Modules linked in: spi_s3c64xx(+) spidev fa_cpu_pfn(P)[&c0178c44&] (unwind_backtrace+0x0/0xe4) from [&c0188150&] (warn_slowpath_common+0x4c/0x64)[&c0188150&] (warn_slowpath_common+0x4c/0x64) from [&c01881e8&] (warn_slowpath_fmt+0x2c/0x3c)[&c01881e8&] (warn_slowpath_fmt+0x2c/0x3c) from [&c02e486c&] (gpio_ensure_requested+0x48/0xf4)[&c02e486c&] (gpio_ensure_requested+0x48/0xf4) from [&c02e4a5c&] (gpio_direction_output+0x68/0x120)[&c02e4a5c&] (gpio_direction_output+0x68/0x120) from [&bf00d614&] (s3c64xx_spi_setup+0x1ec/0x204 [spi_s3c64xx])[&bf00d614&] (s3c64xx_spi_setup+0x1ec/0x204 [spi_s3c64xx]) from [&c034516c&] (spi_setup+0x40/0x48)[&c034516c&] (spi_setup+0x40/0x48) from [&c03453f4&] (spi_add_device+0xa0/0x118)[&c03453f4&] (spi_add_device+0xa0/0x118) from [&c03454ec&] (spi_new_device+0x80/0xa4)[&c03454ec&] (spi_new_device+0x80/0xa4) from [&c0345530&] (spi_match_master_to_boardinfo+0x20/0x40)[&c0345530&] (spi_match_master_to_boardinfo+0x20/0x40) from [&c0345624&] (spi_register_master+0xd4/0x118)[&c0345624&] (spi_register_master+0xd4/0x118) from [&bf0113d4&] (s3c64xx_spi_probe+0x3d4/0x4a8 [spi_s3c64xx])[&bf0113d4&] (s3c64xx_spi_probe+0x3d4/0x4a8 [spi_s3c64xx]) from [&c031530c&] (platform_drv_probe+0x14/0x18)[&c031530c&] (platform_drv_probe+0x14/0x18) from [&c0314500&] (driver_probe_device+0xa8/0x158)[&c0314500&] (driver_probe_device+0xa8/0x158) from [&c0314610&] (__driver_attach+0x60/0x84)[&c0314610&] (__driver_attach+0x60/0x84) from [&c03137e8&] (bus_for_each_dev+0x4c/0x78)[&c03137e8&] (bus_for_each_dev+0x4c/0x78) from [&c0313e84&] (bus_add_driver+0xa8/0x224)[&c0313e84&] (bus_add_driver+0xa8/0x224) from [&c031485c&] (driver_register+0xa8/0x12c)[&c031485c&] (driver_register+0xa8/0x12c) from [&c0315570&] (platform_driver_probe+0x18/0x8c)[&c0315570&] (platform_driver_probe+0x18/0x8c) from [&c01694d8&] (do_one_initcall+0xbc/0x190)[&c01694d8&] (do_one_initcall+0xbc/0x190) from [&c01af348&] (sys_init_module+0x158c/0x1754)[&c01af348&] (sys_init_module+0x158c/0x1754) from [&c01735e0&] (ret_fast_syscall+0x0/0x30)---[ end trace fa984f295d032b1b ]---------------[ cut here ]------------WARNING: at drivers/gpio/gpiolib.c:99 gpio_ensure_requested+0x48/0xf4()autorequest GPIO-24Modules linked in: spi_s3c64xx(+) spidev fa_cpu_pfn(P)[&c0178c44&] (unwind_backtrace+0x0/0xe4) from [&c0188150&] (warn_slowpath_common+0x4c/0x64)[&c0188150&] (warn_slowpath_common+0x4c/0x64) from [&c01881e8&] (warn_slowpath_fmt+0x2c/0x3c)[&c01881e8&] (warn_slowpath_fmt+0x2c/0x3c) from [&c02e486c&] (gpio_ensure_requested+0x48/0xf4)[&c02e486c&] (gpio_ensure_requested+0x48/0xf4) from [&c02e4a5c&] (gpio_direction_output+0x68/0x120)[&c02e4a5c&] (gpio_direction_output+0x68/0x120) from [&bf00d614&] (s3c64xx_spi_setup+0x1ec/0x204 [spi_s3c64xx])[&bf00d614&] (s3c64xx_spi_setup+0x1ec/0x204 [spi_s3c64xx]) from [&c034516c&] (spi_setup+0x40/0x48)[&c034516c&] (spi_setup+0x40/0x48) from [&c03453f4&] (spi_add_device+0xa0/0x118)[&c03453f4&] (spi_add_device+0xa0/0x118) from [&c03454ec&] (spi_new_device+0x80/0xa4)[&c03454ec&] (spi_new_device+0x80/0xa4) from [&c0345530&] (spi_match_master_to_boardinfo+0x20/0x40)[&c0345530&] (spi_match_master_to_boardinfo+0x20/0x40) from [&c0345624&] (spi_register_master+0xd4/0x118)[&c0345624&] (spi_register_master+0xd4/0x118) from [&bf0113d4&] (s3c64xx_spi_probe+0x3d4/0x4a8 [spi_s3c64xx])[&bf0113d4&] (s3c64xx_spi_probe+0x3d4/0x4a8 [spi_s3c64xx]) from [&c031530c&] (platform_drv_probe+0x14/0x18)[&c031530c&] (platform_drv_probe+0x14/0x18) from [&c0314500&] (driver_probe_device+0xa8/0x158)[&c0314500&] (driver_probe_device+0xa8/0x158) from [&c0314610&] (__driver_attach+0x60/0x84)[&c0314610&] (__driver_attach+0x60/0x84) from [&c03137e8&] (bus_for_each_dev+0x4c/0x78)[&c03137e8&] (bus_for_each_dev+0x4c/0x78) from [&c0313e84&] (bus_add_driver+0xa8/0x224)[&c0313e84&] (bus_add_driver+0xa8/0x224) from [&c031485c&] (driver_register+0xa8/0x12c)[&c031485c&] (driver_register+0xa8/0x12c) from [&c0315570&] (platform_driver_probe+0x18/0x8c)[&c0315570&] (platform_driver_probe+0x18/0x8c) from [&c01694d8&] (do_one_initcall+0xbc/0x190)[&c01694d8&] (do_one_initcall+0xbc/0x190) from [&c01af348&] (sys_init_module+0x158c/0x1754)[&c01af348&] (sys_init_module+0x158c/0x1754) from [&c01735e0&] (ret_fast_syscall+0x0/0x30)---[ end trace fa984f295d032b1c ]---[root@FriendlyARM /home]# [root@FriendlyARM /home]#
级别: 论坛版主
发帖: 5407
金钱: 40120 两
威望: 17929 点
贡献值: 71 点
综合积分: 11054 分
&回 1楼() 的帖子
这个错误信息不会导致SPI的硬件通信问题,它只是在你没有调用gpio_request的情况下就操作相应gpio的情况下的一个警告。我想通信的问题还是需要从SPI上的读取和发出数据分析入手。
&If you have an apple and I have an apple and we exchange apples, then you and I willstill each have one apple. But if you have an idea and I have an idea and we exchangethese ideas, then each of us will have two ideas.&
专注与嵌入式linux的图像,视频方向的开发。
级别: 侠客
金钱: 405 两
威望: 81 点
贡献值: 0 点
综合积分: 162 分
哦,谢谢了,你说的GPIO是不是 SPI的&& .line=S3C64XX_GPC(3), 这个引脚,因为只有这个引脚的我调用GPIO的库来设置的。现在的问题是:我能确定SPI的 CLK MISO MOSI是正常的,因为我把发送和接收脚短接,发现发送和接收数据完全正常的。但我现在不能保证&&.line=S3C64XX_GPC(3), 这个引脚是不是正常的,因为我在实际中发现 当外面接上spi的芯片时,小数据(比如读写某个寄存器)是正常的,但是如果大数据量 就会出现接收的数据错误, 请教下!!谢谢了!
专注与嵌入式linux的图像,视频方向的开发。
级别: 侠客
金钱: 405 两
威望: 81 点
贡献值: 0 点
综合积分: 162 分
请问下楼主,我一直怀疑是 spi的cs脚 没有正常的拉高或拉低导致的,请问下这个SPI的cs脚只是设置了输出,他会自动的把GPC3脚设置为输出模式,并且是输出为1或0 吗,谢谢!
级别: 论坛版主
发帖: 5407
金钱: 40120 两
威望: 17929 点
贡献值: 71 点
综合积分: 11054 分
&回 4楼() 的帖子
负责输出0或1的是下面的代码:在头文件语句的下面增加&& &&&& static void&&cs_set_level(unsigned line_id, int lvl) {&&&&gpio_direction_output(line_id, lvl);};static struct s3c64xx_spi_csinfo s3c64xx_spi0_csinfo = {&&.fb_delay=100,&&.line=S3C64XX_GPC(3),&&.set_level=cs_set_level,};另外,在gpio_direction_output()里最终应该会调用到arch/arm/plat-samsung/gpio.c里的 s3c_gpiolib_output()函数,在它里面会把对应GPIO的模式设置成output 67 static int s3c_gpiolib_output(struct gpio_chip *chip, 68&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& unsigned offset, int value) 69 { 70&&&&&&&& struct s3c_gpio_chip *ourchip = to_s3c_gpio(chip); 71&&&&&&&& void __iomem *base = ourchip-& 72&&&&&&&& 73&&&&&&&& 74&&&&&&&& 75
76&&&&&&&& s3c_gpio_lock(ourchip, flags); 77
78&&&&&&&& dat = __raw_readl(base + 0x04); 79&&&&&&&& dat &= ~(1 && offset); 80&&&&&&&& if (value) 81&&&&&&&&&&&&&&&& dat |= 1 && 82&&&&&&&& __raw_writel(dat, base + 0x04); 83
84&&&&&&&& con = __raw_readl(base + 0x00); 85&&&&&&&& con &= ~(3 && (offset * 2)); 86&&&&&&&& con |= 1 && (offset * 2); 87
88&&&&&&&& __raw_writel(con, base + 0x00); 89&&&&&&&& __raw_writel(dat, base + 0x04); 90
91&&&&&&&& s3c_gpio_unlock(ourchip, flags); 92&&&&&&&& return 0; 93 }
&If you have an apple and I have an apple and we exchange apples, then you and I willstill each have one apple. But if you have an idea and I have an idea and we exchangethese ideas, then each of us will have two ideas.&
专注与嵌入式linux的图像,视频方向的开发。
级别: 侠客
金钱: 405 两
威望: 81 点
贡献值: 0 点
综合积分: 162 分
感谢总版主,亲自找到源代码的位置并贴出来, 让人感动啊。!我在积极的找这个问题的解决的办法,等找到了,贴上来,以免以后有人也遇到这样的问题,谢谢了
级别: 论坛版主
发帖: 5407
金钱: 40120 两
威望: 17929 点
贡献值: 71 点
综合积分: 11054 分
&回 6楼() 的帖子
这没有什么。在我看来,在这里讨论问题如果脱离了源代码,是一点意义也没有的。事实上这也是论坛上很多问题得不到解决的一个重要原因。
&If you have an apple and I have an apple and we exchange apples, then you and I willstill each have one apple. But if you have an idea and I have an idea and we exchangethese ideas, then each of us will have two ideas.&
级别: 新手上路
金钱: 50 两
威望: 10 点
贡献值: 0 点
综合积分: 18 分
拜读了。。。
级别: 新手上路
金钱: 35 两
威望: 7 点
贡献值: 0 点
综合积分: 14 分
请问楼主现在这个问题解决了吗,后来人又遇到同样问题了,求指导啊~~
1 Pages: 1/2& & &Go
Powered by

我要回帖

更多关于 开发板驱动 的文章

 

随机推荐