• «
  • 1
  • 2
  • »
  • Pages: 1/2     Go
主题 : 关于mini2440的linux-2.6.29中uda1341声卡移植求助 复制链接 | 浏览器收藏 | 打印
USR组织-奉献、分享、合作、自律
级别: 新手上路
UID: 4067
精华: 0
发帖: 17
金钱: 180 两
威望: 180 点
综合积分: 34 分
注册时间: 2009-02-23
最后登录: 2009-04-30
楼主  发表于: 2009-04-10 15:56

 关于mini2440的linux-2.6.29中uda1341声卡移植求助

你好,我想了解一下,在你们做2.6.29移植uda1341声卡驱动时,改变过的和新加入都是哪些文件,我正在做2.6.28的移植 ,想做个参考。另外,mkyaffsimage工具的生成文件能不能也放出来?尝试过做yaffs的移植,但多次都没有成功啊!
[ 此帖被dean_go在2009-04-10 19:12重新编辑 ]
这个阶段正是我事业的上升期,我怎么能走得开呢?
级别: 精灵王
UID: 3197
精华: 3
发帖: 770
金钱: 6995 两
威望: 5398 点
综合积分: 1600 分
注册时间: 2008-12-30
最后登录: 2010-12-31
1楼  发表于: 2009-04-10 16:16
新系统把这些都已经做好了,见本论坛的"FriendlyARM官方最新动态",里面有下载地址。
USR组织-奉献、分享、合作、自律
级别: 新手上路
UID: 4067
精华: 0
发帖: 17
金钱: 180 两
威望: 180 点
综合积分: 34 分
注册时间: 2009-02-23
最后登录: 2009-04-30
2楼  发表于: 2009-04-10 19:12

 回 1楼(26672624) 的帖子

没读我的帖子,请不要乱回复,烦人。
这个阶段正是我事业的上升期,我怎么能走得开呢?
级别: 精灵王
UID: 3197
精华: 3
发帖: 770
金钱: 6995 两
威望: 5398 点
综合积分: 1600 分
注册时间: 2008-12-30
最后登录: 2010-12-31
3楼  发表于: 2009-04-10 22:25
diff一下什么都看到了,脾气还不小。
*無鈳取玳
级别: 论坛版主
UID: 27
精华: 12
发帖: 5398
金钱: 40120 两
威望: 17929 点
综合积分: 11036 分
注册时间: 2008-01-16
最后登录: 2014-11-22
4楼  发表于: 2009-04-11 21:26
UDA134x driver for S3C24x0 in Linux 2.6.29 is part of ASoc project (ALSA System On Chip, http://opensource.wolfsonmicro.com/node/6)

The main source code is located at:
sound/soc/codecs/uda134x.c             --  UDA134x codec driver
sound/soc/s3c24xx/s3c24xx-i2s.c         --  S3C24xx I2S driver
sound/soc/s3c24xx/s3c24xx_uda134x.c   -- S3C24xx based board specific configuration for UDA134x

The code needed to add to use this driver is "platform device" configuration for s3c24xx uda134x in kernel machine specific source code, e.g. following code piece in arch/arm/mach-s3c2440/mach-mini2440.c:

复制代码
  1. static struct s3c24xx_uda134x_platform_data s3c24xx_uda134x_data = {
  2.         .l3_clk = S3C2410_GPB4,
  3.         .l3_data = S3C2410_GPB3,
  4.         .l3_mode = S3C2410_GPB2,
  5.         .model = UDA134X_UDA1341,
  6. };
  7. static struct platform_device s3c24xx_uda134x = {
  8.         .name = "s3c24xx_uda134x",
  9.         .dev = {
  10.                 .platform_data    = &s3c24xx_uda134x_data,
  11.         }
  12. };


and add this "platform device":
复制代码
  1. static struct platform_device *mini2440_devices[] __initdata = {
  2.         ...
  3.         &s3c24xx_uda134x,
  4. };


I suggest you take a look at Asoc project page and basic info of Linux Driver Model of 2.6 kernel before using this driver.
"If you have an apple and I have an apple and we exchange apples, then you and I will
still each have one apple. But if you have an idea and I have an idea and we exchange
these ideas, then each of us will have two ideas."
*無鈳取玳
级别: 论坛版主
UID: 27
精华: 12
发帖: 5398
金钱: 40120 两
威望: 17929 点
综合积分: 11036 分
注册时间: 2008-01-16
最后登录: 2014-11-22
5楼  发表于: 2009-04-11 21:38
另外我想说明的是, 26672624说的其实并没错,作为开发者,不要总期待别人会“好心”告诉你他每一步是如何如何做的,要善于利用源代码工具,其中diff和patch命令就是最有用的工具之一。
只要你找到别人的最终成果(友善之臂提供的2.6.29的内核)和他的基础(原始的2.6.29内核源代码),它可以帮你找出别人"所做的事情"(例如,diff -Nuapr linux-2.6.29 linux-2.6.29-mini2440 > linux-2.6.29-mini2440.patch)并很容易的让你重复利用(patch -p1 < linux-2.6.29-mini2440.patch)。
"If you have an apple and I have an apple and we exchange apples, then you and I will
still each have one apple. But if you have an idea and I have an idea and we exchange
these ideas, then each of us will have two ideas."
*無鈳取玳
级别: 论坛版主
UID: 27
精华: 12
发帖: 5398
金钱: 40120 两
威望: 17929 点
综合积分: 11036 分
注册时间: 2008-01-16
最后登录: 2014-11-22
6楼  发表于: 2009-04-11 21:48
ASoc S3C24xx UDA134x driver was added in 2.6.29-rc1, so you need to apply following patches manually to add this driver if you use 2.6.28 kernel. In addition, you may need to modify some of these code since they're based on 2.6.29-rc1 kernel

1. patch to add UDA134x ASoc codec driver   asoc_uda134x.patch.zip (7 K) 下载次数:77
2. patch to add S3C24xx UDA134x driver   asoc_s3c24x_uda134x.patch.zip (5 K) 下载次数:66

Usage:
1. unzip patches downloaded
2. apply patches as
$ cd /path/to/your/kernel/source/directory
$ patch -p1 < /path/to/extracted/patch/file
3. add S3C24xx UDA134x "platform device" to your machine specific file, e.g. arch/arm/mach-s3c2440/machine-smdk2440.c, as Friendly ARM does
4. re-configure your kernel properly to use this driver.
[ 此帖被kasim在2009-04-11 21:54重新编辑 ]
"If you have an apple and I have an apple and we exchange apples, then you and I will
still each have one apple. But if you have an idea and I have an idea and we exchange
these ideas, then each of us will have two ideas."
级别: 侠客
UID: 8904
精华: 0
发帖: 54
金钱: 400 两
威望: 155 点
综合积分: 108 分
注册时间: 2009-09-10
最后登录: 2017-09-13
7楼  发表于: 2009-09-10 10:37
请教一下:我按照4楼所说的改的2.6.29的内核,启动信息里显示No device for dai uda134x和No device for dai s3c24xx-i2s,建立不了dsp节点,请问是什么原因,谢谢。
*無鈳取玳
级别: 论坛版主
UID: 27
精华: 12
发帖: 5398
金钱: 40120 两
威望: 17929 点
综合积分: 11036 分
注册时间: 2008-01-16
最后登录: 2014-11-22
8楼  发表于: 2009-09-10 10:50

 回 7楼(aoxing) 的帖子

贴出完整的内核启动log
"If you have an apple and I have an apple and we exchange apples, then you and I will
still each have one apple. But if you have an idea and I have an idea and we exchange
these ideas, then each of us will have two ideas."
级别: 侠客
UID: 8904
精华: 0
发帖: 54
金钱: 400 两
威望: 155 点
综合积分: 108 分
注册时间: 2009-09-10
最后登录: 2017-09-13
9楼  发表于: 2009-09-10 12:04

 回 8楼(kasim) 的帖子

下面是启动信息,帮忙看一下,谢谢。
VIVI version 0.1.4 (root@jones) (gcc version 2.95.3 20010315 (release)) #0.1.4 27 16:19:23 CST 2009
MMU table base address = 0x33DFC000
Succeed memory mapping.
NAND device: Manufacture ID: 0xec, Chip ID: 0x76 (Samsung K9D1208V0M)
Found saved vivi parameters.
Press Return to start the LINUX now, any other key for vivi
Copy linux kernel from 0x00030000 to 0x30008000, size = 0x00300000 ... done
zImage magic = 0x016f2818
Setup linux parameters at 0x30000100
linux command line is: "root=1f03 init=/linuxrc console=ttySAC0"
MACH_TYPE = 193
NOW, Booting Linux......
Uncompressing Linux.............................................................................................................................................................. done, booting the kernel.
Linux version 2.6.29 (root@jones) (gcc version 3.4.1) #58 Thu Sep 10 11:00:06 CST 2009
CPU: ARM920T [41129200] revision 0 (ARMv4T), cr=c0007177
CPU: VIVT data cache, VIVT instruction cache
Machine: SMDK2410
ATAG_INITRD is deprecated; please update your bootloader.
Memory policy: ECC disabled, Data cache writeback
CPU S3C2410 (id 0x32410000)
S3C24XX Clocks, (c) 2004 Simtec Electronics
S3C2410: core 200.000 MHz, memory 100.000 MHz, peripheral 50.000 MHz
CLOCK: Slow mode (1.500 MHz), fast, MPLL on, UPLL on
USB Control,(c)2006 bblove
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256
Kernel command line: root=1f03 init=/linuxrc console=ttySAC0
irq: clearing subpending status 00000003
irq: clearing subpending status 00000002
PID hash table entries: 256 (order: 8, 1024 bytes)
Console: colour dummy device 80x30
console [ttySAC0] enabled
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory: 64MB = 64MB total
Memory: 59676KB available (4364K code, 411K data, 420K init)
Calibrating delay loop... 99.53 BogoMIPS (lpj=248832)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
net_namespace: 760 bytes
NET: Registered protocol family 16
S3C2410 Power Management, (c) 2004 Simtec Electronics
S3C2410: Initialising architecture
S3C24XX DMA Driver, (c) 2003-2004,2006 Simtec Electronics
DMA channel 0 at c4808000, irq 33
DMA channel 1 at c4808040, irq 34
DMA channel 2 at c4808080, irq 35
DMA channel 3 at c48080c0, irq 36
bio: create slab <bio-0> at 0
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 2048 (order: 2, 16384 bytes)
TCP bind hash table entries: 2048 (order: 3, 40960 bytes)
TCP: Hash tables configured (established 2048 bind 2048)
TCP reno registered
NET: Registered protocol family 1
NetWinder Floating Point Emulator V0.97 (extended precision)
Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
NTFS driver 2.1.29 [Flags: R/W].
JFFS2 version 2.2. (NAND) (SUMMARY)  漏 2001-2006 Red Hat, Inc.
fuse init (API version 7.11)
yaffs Sep  9 2009 12:03:08 Installing.
msgmni has been set to 116
alg: No test for stdrng (krng)
io scheduler noop registered
io scheduler anticipatory registered (default)
io scheduler deadline registered
io scheduler cfq registered
Console: switching to colour frame buffer device 80x30
fb0: s3c2410fb frame buffer device
lp: driver loaded but no devices found
ppdev: user-space parallel port driver
Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
s3c2410-uart.0: s3c2410_serial0 at MMIO 0x50000000 (irq = 70) is a S3C2410
s3c2410-uart.1: s3c2410_serial1 at MMIO 0x50004000 (irq = 73) is a S3C2410
s3c2410-uart.2: s3c2410_serial2 at MMIO 0x50008000 (irq = 76) is a S3C2410
brd: module loaded
loop: module loaded
usbcore: registered new interface driver ub
PPP generic driver version 2.4.2
PPP Deflate Compression module registered
PPP BSD Compression module registered
NET: Registered protocol family 24
dm9000 Ethernet Driver, V1.31
eth0 (dm9000): not using net_device_ops yet
eth0: dm9000e at c486e000,c4872002 IRQ 18 MAC: 08:08:08:08:12:27 (chip)
Driver 'sd' needs updating - please use bus_type methods
S3C24XX NAND Driver, (c) 2004 Simtec Electronics
s3c2410-nand s3c2410-nand: Tacls=1, 10ns Twrph0=4 40ns, Twrph1=1 10ns
NAND device: Manufacturer ID: 0xec, Chip ID: 0x76 (Samsung NAND 64MiB 3,3V 8-bit)
NAND_ECC_NONE selected by board driver. This is not recommended !!
Scanning device for bad blocks
Bad eraseblock 833 at 0x000000d04000
Bad eraseblock 2293 at 0x0000023d4000
Creating 5 MTD partitions on "NAND 64MiB 3,3V 8-bit":
0x000000000000-0x000000020000 : "vivi"
0x000000020000-0x000000030000 : "param"
0x000000030000-0x000000330000 : "S3C2410 kernel"
0x000000330000-0x000000630000 : "S3C2410 root"
0x000000630000-0x000003f30000 : "s3c2410 yaffs"
usbmon: debugfs is not available
ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
s3c2410-ohci s3c2410-ohci: S3C24XX OHCI
s3c2410-ohci s3c2410-ohci: new USB bus registered, assigned bus number 1
s3c2410-ohci s3c2410-ohci: irq 42, io mem 0x49000000
usb usb1: configuration #1 chosen from 1 choice
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 2 ports detected
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
s3c2410 TouchScreen successfully loaded
input: s3c2410 TouchScreen as /class/input/input0
s3c2410-i2c s3c2410-i2c: slave address 0x10
s3c2410-i2c s3c2410-i2c: bus frequency set to 390 KHz
s3c2410-i2c s3c2410-i2c: i2c-0: S3C I2C adapter
usbcore: registered new interface driver usbhid
usbhid: v2.6:USB HID core driver
Advanced Linux Sound Architecture Driver Version 1.0.18a.
No device for DAI UDA134X
No device for DAI s3c24xx-i2s

S3C24XX_UDA134X SoC Audio driver
UDA134X SoC Audio Codec
asoc: UDA134X <-> s3c24xx-i2s mapping ok
ALSA device list:
  #0: S3C24XX_UDA134X (UDA134X)
TCP cubic registered
NET: Registered protocol family 17
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
VFS: Mounted root (cramfs filesystem) readonly on device 31:3.
Freeing init memory: 420K
mount /etc as ramfs

init started: BusyBox v1.9.2 (2009-06-19 10:24:50 CST)

starting pid 880, tty '': '/etc/init.d/rcS'
#mount all.......
mount: mounting none on /dev/pts failed: No such file or directory
mount: mounting tmpfs on /dev/shm failed: No such file or directory
chmod: /dev/null: Read-only file system
starting mdev....
yaffs: dev is 32505860 name is "mtdblock4"
yaffs: passed flags ""
yaffs: Attempting MTD mount on 31.4, "mtdblock4"
yaffs: block 437 is marked bad
block 438 is bad
yaffs: block 1897 is marked bad
block 1898 is bad
yaffs_read_super: isCheckpointed 0
eth0: link down

starting pid 893, tty '': '/bin/sh'

Processing /etc/profile......-/bin/sh: alias: not found
Done!
[root@root/]#eth0: link up, 100Mbps, full-duplex, lpa 0xCDE1
[ 此帖被aoxing在2009-09-10 13:24重新编辑 ]
  • «
  • 1
  • 2
  • »
  • Pages: 1/2     Go