Latest LQ Deal: Latest LQ Deals
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 08-19-2008, 03:19 AM   #1
LQ Newbie
Registered: Jul 2008
Posts: 27

Rep: Reputation: 15
how to know misc_register() have run

Hi all,

I read a tutorial about device driver, especially for Miscellaneous Character Drivers which is employed two functions (misc_register and misc_unregister).

I put here some source code
static int	__init backlight_init(void)
	misc_register( &backlight_dev );

	printk(" backlight device driver register \n");

	return 0;
I can compiled and insert that module to kernel. However, according the tutorial in

After successful registration, the new misc device will appear in /proc/misc. But i try to reach the directory by using (ls -l /proc/misc) there isn't a new misc device.

Please help me
Old 08-19-2008, 04:35 AM   #2
Senior Member
Registered: Apr 2004
Location: Brisbane, Australia
Distribution: Devuan
Posts: 3,414
Blog Entries: 33

Rep: Reputation: 222Reputation: 222Reputation: 222
Hi, Try

ls -l /proc/misc/
Old 08-19-2008, 06:31 AM   #3
LQ Guru
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 678Reputation: 678Reputation: 678Reputation: 678Reputation: 678Reputation: 678
Did you read "listing 1" in the article?
Old 08-19-2008, 07:32 AM   #4
LQ Newbie
Registered: Aug 2008
Posts: 1

Rep: Reputation: 0

all the best !
Old 08-19-2008, 07:47 PM   #5
LQ Newbie
Registered: Jul 2008
Posts: 27

Original Poster
Rep: Reputation: 15
Originally Posted by GlennsPref View Post
Hi, Try

ls -l /proc/misc/
Yes i have tried ls -l /proc/misc
but it look like the misc is not directory, so i cannot find the backlight as name of driver. Actually this is my question core.
Old 08-19-2008, 07:56 PM   #6
LQ Newbie
Registered: Jul 2008
Posts: 27

Original Poster
Rep: Reputation: 15
Originally Posted by jschiwal View Post
Did you read "listing 1" in the article?
I didn't make the "listing 1", instead of I follow this:

#insmod backlight.o
#mknod /dev/backlight c 10 63  {i found minor number from my coding}
#chomod a+rw /dev/backlight
But i still cannot look if there is new file in /proc/misc

PS. basic question, you mention about script in "listing 1", how to make and run this script?
Old 08-20-2008, 04:55 AM   #7
LQ Newbie
Registered: Jul 2008
Posts: 27

Original Poster
Rep: Reputation: 15
Oke, for this question, i got the answer, i found my driver when i use this command:

[root@tb-xt lcd]$cat /proc/misc
 63 backlight
 69 tynuxpm
 15 touchscreen/wm9705
135 rtc
[root@tb-xt lcd]$
But I still need more explanation for connecting between user space to kernel space. I will post a new thread for this


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
I run Fedora 9 and I boot from USB, how I run at startup Firewall and antivirus? gginis Linux - Software 3 06-08-2008 04:19 AM
computer asks me to run a FSCK Manually, but won't : says can't run on mounted lightwave Linux - Newbie 12 04-02-2008 01:25 AM
Is a script, run at boot time from init.d, run with root authority? tmbrwolf53 Linux - Server 2 03-31-2007 09:15 PM
A lot of processes run automatically when I run a single process. dalvirgautam Linux - Enterprise 4 12-01-2006 07:10 PM
Cannot get to run properly doctorwebbox Linux - Hardware 0 02-06-2005 07:18 AM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 01:22 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration