-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Steve Ressler wrote: > Hi, > >>Are you sure that resizer takes major number 254? I guess it uses >>dynamic number allocation. > > > I believe you are correct, it uses dynamic number allocation. 254 was the > number > I saw it using when the device file was created by the init scripts. How can > I > find the correct major number? I'm not running the init scripts, so there is > nothing in /proc to check. > > Maybe I should have asked: How can I use the resizer without running the init > scripts? >
AFAIK, you cannot check device numbers without proc or sysfs. Some options coming to mind: 1) Edit resizer driver drivers/char/davinci_resizer.c Change line: result = alloc_chrdev_region(&dev, ZERO, 1, DRIVER_NAME); to: dev = MKDEV(254_or_some_number_unique_in_the_system, ZERO); result = register_chrdev_region(dev, 1, DRIVER_NAME); Don't forget to create node for the number you choose as major. 2) Create a file in your filesystem and edit, let's say /home/my_init.sh: #!/bin/sh mount /proc RES=$(cat /proc/devices | awk '/davinci_resizer/ {print $1}') rm -f /dev/resizer mknod /dev/resizer c $RES 0 /path/to/your/app/app Then start this script as init, instead of your application. 3) You can also edit your inittab. Instead of running init scripts you can just mount some filesystems and then start your application. I don't use MV fs and kernel, so I can't try these. But I guess they may give some ideas. Regards, Caglar -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org iEYEARECAAYFAkl4mH4ACgkQ/nL+S5dojeht1QCfVRqG0HxB7zqUIs6c2l4QRhrC /3YAoJb573wRtHKDi0ArFEqk83wrOKI5 =3nas -----END PGP SIGNATURE----- _______________________________________________ Davinci-linux-open-source mailing list Davinci-linux-open-source@linux.davincidsp.com http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source