SlideShare a Scribd company logo
1 of 10
Download to read offline
Linux Device Driver
Agenda

   History & Why Linux kernel?
   Device Driver.
       Purpose & Design
       Kernel mode & User mode
       Development
       Application & API
History and Why Linux kernel?

   First developed by Linus Torvals.
   Linux base on UNIX standard.
   Workgroup for implement driver
    & patch with kernel.org.
   ”Just for fun” - Linux Torvals
    History.
Pupose & Design

   Connection between Hardware and Software.
                 Design communicate on logical
                   layer ( Port : ttyS,lp,hd) and
                   physical layer(Handle stardard
                   of communication protocol).
                 Linux kernel (.ko file type) &

                   Microsoft (.sys file type )
                   kernel( Monolithic,Micro,Hybird
                   )
Linux boot sequence on x86
                                                     x86 Real Mode

   BIOS
   Bootloader ( GRUB/LILO )
   Real Mode Kernel
                                                      X86 Protected
            Arch/x86/boot/pm.c                            Mode

   Protected Mode kernel
   The init Process
   User Processes and Daemons


          Booting up,Essential Linux Device Drivers-Venkateswaran.
User & Kernel mode.


    Kernel Mode
       It can execute any CPU instruction and reference
        any memory address. Kernel mode is generally
        reserved for the lowest-level”.
       Most, ”trusted functions of the operating system”.

    User Mode
       In User mode, the executing code has no ability to
        directly access hardware or reference memory.
       Code running in user mode must delegate to
        system APIs to access hardware or memory.
                      Understanding user & kernel mode,Coding Horror-Jeff Atwood
Development

   Linux System Call.
   Device Drivers Development Supporting device
    drivers.
   Kernel Programming Environment.
Linux System Call

   Executing in kernel mode.
       Kernel mode recognize and particular action
        is require from the device.
       Call to device routine which pass user
        process to device routine.
       Device routine may be shared
        simulataneously by user application
Device Drivers Development
      Supporting device drivers.
   A set of routines that communicate with a hardware
    device and provide a uniform interface to the operating
    system kernel.
   A self-contained component that can be added to, or
    removed from, the operating system dynamically.
   Management of data flow and c ontrol between user
    programs and a peripheral device.
   A user-defined section of the kernel that allows a
    program or a peripheral device to appear as a `` /dev
    '' device to the rest of the system's software.

                       Write a Linux Hardware Device Driver.FreeSoftware Mag.
Device Driver Programming
                                                         % make
#include <linux/init.h>
#include <linux/module.h>                                make[1]: Entering directory `/usr/src/linux-2.6.10'

MODULE_LICENSE("Dual BSD/GPL");                          CC [M] /home/ldd3/src/misc-modules/hello.o

                                                         Building modules, stage 2.
static int hello_init(void)                              MODPOST
{                                                        CC
printk(KERN_ALERT "Hello, worldn");
                                                         /home/ldd3/src/misc-modules/hello.mod.o
return 0;
                                                         LD [M] /home/ldd3/src/misc-modules/hello.ko
}
                                                         make[1]: Leaving directory `/usr/src/linux-2.6.10'

static void hello_exit(void)                             % su

{                                                        root# insmod ./hello.ko
printk(KERN_ALERT "Goodbye, cruel worldn");             Hello, world
}                                                        root# rmmod hello

                                                         Goodbye cruel world
module_init(hello_init);
                                                         root#
module_exit(hello_exit);



                                       Linux kernel in a nutshell,3rd-Greg Kroah-Hartman

More Related Content

What's hot (20)

Linux booting procedure
Linux booting procedureLinux booting procedure
Linux booting procedure
 
Linux Porting to a Custom Board
Linux Porting to a Custom BoardLinux Porting to a Custom Board
Linux Porting to a Custom Board
 
Linux device drivers
Linux device drivers Linux device drivers
Linux device drivers
 
Basic Linux Internals
Basic Linux InternalsBasic Linux Internals
Basic Linux Internals
 
Embedded linux network device driver development
Embedded linux network device driver developmentEmbedded linux network device driver development
Embedded linux network device driver development
 
U-Boot presentation 2013
U-Boot presentation  2013U-Boot presentation  2013
U-Boot presentation 2013
 
Linux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKBLinux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKB
 
Linux Internals - Part I
Linux Internals - Part ILinux Internals - Part I
Linux Internals - Part I
 
Embedded Operating System - Linux
Embedded Operating System - LinuxEmbedded Operating System - Linux
Embedded Operating System - Linux
 
Linux Ethernet device driver
Linux Ethernet device driverLinux Ethernet device driver
Linux Ethernet device driver
 
Bootloaders (U-Boot)
Bootloaders (U-Boot) Bootloaders (U-Boot)
Bootloaders (U-Boot)
 
Linux device drivers
Linux device driversLinux device drivers
Linux device drivers
 
Linux Initialization Process (1)
Linux Initialization Process (1)Linux Initialization Process (1)
Linux Initialization Process (1)
 
Linux Kernel Development
Linux Kernel DevelopmentLinux Kernel Development
Linux Kernel Development
 
The linux networking architecture
The linux networking architectureThe linux networking architecture
The linux networking architecture
 
Linux kernel debugging
Linux kernel debuggingLinux kernel debugging
Linux kernel debugging
 
Signal
SignalSignal
Signal
 
Shell and its types in LINUX
Shell and its types in LINUXShell and its types in LINUX
Shell and its types in LINUX
 
Linux PCI device driver
Linux PCI device driverLinux PCI device driver
Linux PCI device driver
 
Introduction to char device driver
Introduction to char device driverIntroduction to char device driver
Introduction to char device driver
 

Viewers also liked

Embedded systems training India - Linux system programming and kernel intern...
Embedded systems training India  - Linux system programming and kernel intern...Embedded systems training India  - Linux system programming and kernel intern...
Embedded systems training India - Linux system programming and kernel intern...RR Embedded
 
Linux Device Driver Training-TutorialsDaddy
Linux Device Driver Training-TutorialsDaddyLinux Device Driver Training-TutorialsDaddy
Linux Device Driver Training-TutorialsDaddyStryker King
 
Linux Device Driver Introduction
Linux Device Driver IntroductionLinux Device Driver Introduction
Linux Device Driver IntroductionDavidChen0513
 
Linux Kernel and Driver Development Training
Linux Kernel and Driver Development TrainingLinux Kernel and Driver Development Training
Linux Kernel and Driver Development TrainingStephan Cadene
 
Linux Device Driver parallelism using SMP and Kernel Pre-emption
Linux Device Driver parallelism using SMP and Kernel Pre-emptionLinux Device Driver parallelism using SMP and Kernel Pre-emption
Linux Device Driver parallelism using SMP and Kernel Pre-emptionHemanth Venkatesh
 
Introduction to embedded linux device driver and firmware
Introduction to embedded linux device driver and firmwareIntroduction to embedded linux device driver and firmware
Introduction to embedded linux device driver and firmwaredefinecareer
 
Arm device tree and linux device drivers
Arm device tree and linux device driversArm device tree and linux device drivers
Arm device tree and linux device driversHoucheng Lin
 

Viewers also liked (11)

Embedded Android : System Development - Part II (Linux device drivers)
Embedded Android : System Development - Part II (Linux device drivers)Embedded Android : System Development - Part II (Linux device drivers)
Embedded Android : System Development - Part II (Linux device drivers)
 
Embedded systems training India - Linux system programming and kernel intern...
Embedded systems training India  - Linux system programming and kernel intern...Embedded systems training India  - Linux system programming and kernel intern...
Embedded systems training India - Linux system programming and kernel intern...
 
Linux Device Driver Training-TutorialsDaddy
Linux Device Driver Training-TutorialsDaddyLinux Device Driver Training-TutorialsDaddy
Linux Device Driver Training-TutorialsDaddy
 
Linux Device Driver Training
Linux Device Driver TrainingLinux Device Driver Training
Linux Device Driver Training
 
Linux Device Driver Introduction
Linux Device Driver IntroductionLinux Device Driver Introduction
Linux Device Driver Introduction
 
Peek into linux_device_driver_kit
Peek into linux_device_driver_kitPeek into linux_device_driver_kit
Peek into linux_device_driver_kit
 
Linux Kernel and Driver Development Training
Linux Kernel and Driver Development TrainingLinux Kernel and Driver Development Training
Linux Kernel and Driver Development Training
 
Linux Device Driver parallelism using SMP and Kernel Pre-emption
Linux Device Driver parallelism using SMP and Kernel Pre-emptionLinux Device Driver parallelism using SMP and Kernel Pre-emption
Linux Device Driver parallelism using SMP and Kernel Pre-emption
 
Introduction to embedded linux device driver and firmware
Introduction to embedded linux device driver and firmwareIntroduction to embedded linux device driver and firmware
Introduction to embedded linux device driver and firmware
 
LINUX Device Drivers
LINUX Device DriversLINUX Device Drivers
LINUX Device Drivers
 
Arm device tree and linux device drivers
Arm device tree and linux device driversArm device tree and linux device drivers
Arm device tree and linux device drivers
 

Similar to Linux device driver

Similar to Linux device driver (20)

Linux Device Driver’s
Linux Device Driver’sLinux Device Driver’s
Linux Device Driver’s
 
Linux basics
Linux basics Linux basics
Linux basics
 
Device drivers tsp
Device drivers tspDevice drivers tsp
Device drivers tsp
 
Linux basics
Linux basics Linux basics
Linux basics
 
Studienarb linux kernel-dev
Studienarb linux kernel-devStudienarb linux kernel-dev
Studienarb linux kernel-dev
 
Ch1 linux basics
Ch1 linux basicsCh1 linux basics
Ch1 linux basics
 
Walking around linux kernel
Walking around linux kernelWalking around linux kernel
Walking around linux kernel
 
Linuxdd[1]
Linuxdd[1]Linuxdd[1]
Linuxdd[1]
 
Introduction To Linux Kernel Modules
Introduction To Linux Kernel ModulesIntroduction To Linux Kernel Modules
Introduction To Linux Kernel Modules
 
Introduction to Operating Systems.pptx
Introduction to Operating Systems.pptxIntroduction to Operating Systems.pptx
Introduction to Operating Systems.pptx
 
Evolution of Linux Containerization
Evolution of Linux Containerization Evolution of Linux Containerization
Evolution of Linux Containerization
 
Evoluation of Linux Container Virtualization
Evoluation of Linux Container VirtualizationEvoluation of Linux Container Virtualization
Evoluation of Linux Container Virtualization
 
Linux
LinuxLinux
Linux
 
Building
BuildingBuilding
Building
 
Linux kernel driver tutorial vorlesung
Linux kernel driver tutorial vorlesungLinux kernel driver tutorial vorlesung
Linux kernel driver tutorial vorlesung
 
Linux
LinuxLinux
Linux
 
Linux kernel modules
Linux kernel modulesLinux kernel modules
Linux kernel modules
 
Lecture1 Introduction
Lecture1  IntroductionLecture1  Introduction
Lecture1 Introduction
 
brief intro to Linux device drivers
brief intro to Linux device driversbrief intro to Linux device drivers
brief intro to Linux device drivers
 
Linux kernel modules
Linux kernel modulesLinux kernel modules
Linux kernel modules
 

Recently uploaded

Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Principled Technologies
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024The Digital Insurer
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 

Recently uploaded (20)

Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 

Linux device driver

  • 2. Agenda  History & Why Linux kernel?  Device Driver.  Purpose & Design  Kernel mode & User mode  Development  Application & API
  • 3. History and Why Linux kernel?  First developed by Linus Torvals.  Linux base on UNIX standard.  Workgroup for implement driver & patch with kernel.org.  ”Just for fun” - Linux Torvals History.
  • 4. Pupose & Design  Connection between Hardware and Software.  Design communicate on logical layer ( Port : ttyS,lp,hd) and physical layer(Handle stardard of communication protocol).  Linux kernel (.ko file type) & Microsoft (.sys file type ) kernel( Monolithic,Micro,Hybird )
  • 5. Linux boot sequence on x86 x86 Real Mode BIOS Bootloader ( GRUB/LILO ) Real Mode Kernel X86 Protected Arch/x86/boot/pm.c Mode Protected Mode kernel The init Process User Processes and Daemons Booting up,Essential Linux Device Drivers-Venkateswaran.
  • 6. User & Kernel mode.  Kernel Mode  It can execute any CPU instruction and reference any memory address. Kernel mode is generally reserved for the lowest-level”.  Most, ”trusted functions of the operating system”.  User Mode  In User mode, the executing code has no ability to directly access hardware or reference memory.  Code running in user mode must delegate to system APIs to access hardware or memory. Understanding user & kernel mode,Coding Horror-Jeff Atwood
  • 7. Development  Linux System Call.  Device Drivers Development Supporting device drivers.  Kernel Programming Environment.
  • 8. Linux System Call  Executing in kernel mode.  Kernel mode recognize and particular action is require from the device.  Call to device routine which pass user process to device routine.  Device routine may be shared simulataneously by user application
  • 9. Device Drivers Development Supporting device drivers.  A set of routines that communicate with a hardware device and provide a uniform interface to the operating system kernel.  A self-contained component that can be added to, or removed from, the operating system dynamically.  Management of data flow and c ontrol between user programs and a peripheral device.  A user-defined section of the kernel that allows a program or a peripheral device to appear as a `` /dev '' device to the rest of the system's software. Write a Linux Hardware Device Driver.FreeSoftware Mag.
  • 10. Device Driver Programming % make #include <linux/init.h> #include <linux/module.h> make[1]: Entering directory `/usr/src/linux-2.6.10' MODULE_LICENSE("Dual BSD/GPL"); CC [M] /home/ldd3/src/misc-modules/hello.o Building modules, stage 2. static int hello_init(void) MODPOST { CC printk(KERN_ALERT "Hello, worldn"); /home/ldd3/src/misc-modules/hello.mod.o return 0; LD [M] /home/ldd3/src/misc-modules/hello.ko } make[1]: Leaving directory `/usr/src/linux-2.6.10' static void hello_exit(void) % su { root# insmod ./hello.ko printk(KERN_ALERT "Goodbye, cruel worldn"); Hello, world } root# rmmod hello Goodbye cruel world module_init(hello_init); root# module_exit(hello_exit); Linux kernel in a nutshell,3rd-Greg Kroah-Hartman