Linux Driver Assignment9 Usb Febt2013

download Linux Driver Assignment9 Usb Febt2013

of 5

Transcript of Linux Driver Assignment9 Usb Febt2013

  • 8/12/2019 Linux Driver Assignment9 Usb Febt2013

    1/5

    Linux driver assignments USB drivers assignment 9

    1. write a simple module that will search the entire system for all

    available usb physical devices andprint their basic details a! vendor "#$product "#$ device speed and usb space

    address %%%

    b! no. of configurations$ no. of interfaces$ active configuration$ active interface of a configuration and no. of endpoints for a given active interface %%%

    c! "n addition$ also identify the hub devices&root'hub as well!

    which are also devices in a usb bus fabric.

    d! also print the details of the associated driverbound to a given struct interface ( ) ob*ect

  • 8/12/2019 Linux Driver Assignment9 Usb Febt2013

    2/5

    Linux driver assignments USB drivers assignment 9

    +his assignment will give you a hands on tour around the USB fabric representation$ in the usb subsystem

    ,ou can use usb-device-read&! of

    /src0driversusbcoredevices.c as the base code and customi2e the code as needed %%% you must understand this code and also understand your re3uirements$ before you start coding %%%

    4! also verify that the above information correct as per whatyou observe for the corresponding physical and logicaldevices under sysfs you must use information undersysbususbdevices compare information from sysfs$ with

    "nformation generated by your code %%%

  • 8/12/2019 Linux Driver Assignment9 Usb Febt2013

    3/5

    Linux driver assignments USB drivers assignment 9

    5! 6rite a module$ which uses the USBnotifier'chainframe'wor/ of Linux and detects addition of new devices$removal of devices$ addition of buses&hubs! andremoval of buses %%,ou can use chapter 7 of bootstrap USB for the basics

    on notifier chain$ simple module suggested there and customi2e code given for our re3uirements %%%

    ' you must test for events$ during addition removal of devicesbuses by connecting and disconnecting deviceshubs %%%

    ' also print sufficient information about the detect devices buses$ in the notification handler %%%

  • 8/12/2019 Linux Driver Assignment9 Usb Febt2013

    4/5

    8ollowing eading is a must

    ' you must read ch15 of L##5 certain details are notin sync with current /ernel versions$ but basics arevery good %%%

    ' you must also read chapters :$7$;$9 and 1< ofbootstrap usb

    ' refer to custom-usb's/eleton4.c provided with comments %%%

    ' refer to the /ernel source files referred toby the above references and provided in lectures %%%

    ' relevant sections of part one $ five and six ofUSB system architecture =ind share publications %%%

  • 8/12/2019 Linux Driver Assignment9 Usb Febt2013

    5/5

    ' you must read the relevant sections from usb 4.< specification forthe host$ when need this is normally mentioned in the

    above references and /ernel source files %%%

    ' a good understanding of the usb'bus wor/ing is a prere3uisite forwriting usb device drivers %%%