Loading ...
Sorry, an error occurred while loading the content.
 

Re: [blug-prog] Linux Device Driver

Expand Messages
  • maneesh menon
    hello friend, you have spoken about the device normally mknod is used after inserting a driver. i want to know which .c file was infact inserted. where is the
    Message 1 of 6 , Mar 1, 2003
      hello friend,
      you have spoken about the device
      normally mknod is used after inserting a driver.
      i want to know which .c file was infact inserted.
      where is the request for region made !!!
      for a mouse with interface as PS/2 and interrupt line 12
      which is the file from where one has to start reading the kernel
      to write one's own mouse and keyboard driver
      from /usr/src/linux-2.4.7-10/drivers is it ??
      input.c , mousedev.c , mouse_ps2.c , keybdev.c ,pc_keyb.c
      or is it any other !!!
      tell me the starting file
      let me work from there
      with regards,
      anish <anishg3@...> wrote:If u want to use ur mouse driver, make a soft link to /dev/mouse, as I have seen in mine m/c it is /dev/mouse->psaux,
      you do ln -s /dev/mouse /dev/my_mouse_driver.
      and then restart X ctrl+alt+Backspace.
      I hope that shoul work.

      Regards,
      Anish
      ----- Original Message -----
      From: msudipto2002 <msudipto2002@...>
      To: linux-bangalore-programming@yahoogroups.com
      Sent: Tuesday, February 25, 2003 10:47 AM
      Subject: [blug-prog] Linux Device Driver


      I have written a small module of mouse driver in linux. I have loaded
      the module with the help of insmod. The module is successfully
      loaded. Now how can i test my mouse device driver? Can anyone tell me
      exactly what are the steps to be followed after loading a mouse
      module. How to make our driver the default one?How to test our own
      mouse driver?



      Yahoo! Groups Sponsor
      ADVERTISEMENT





      ---------------------------------------------------------------
      This is the programming list of the Bangalore Linux Users Group
      ---------------------------------------------------------------
      Go to http://linux-bangalore.org for more information
      about us, as well as our other mailing lists

      Before you post to this list, please read
      http://linux-bangalore.org/articles/smart-questions.php


      Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



      [Non-text portions of this message have been removed]



      Yahoo! Groups SponsorADVERTISEMENT


      ---------------------------------------------------------------
      This is the programming list of the Bangalore Linux Users Group
      ---------------------------------------------------------------
      Go to http://linux-bangalore.org for more information
      about us, as well as our other mailing lists

      Before you post to this list, please read
      http://linux-bangalore.org/articles/smart-questions.php


      Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

      Catch all the cricket action. Download Yahoo! Score tracker

      [Non-text portions of this message have been removed]
    • Vigneshwar Baliga
      Hi ! Well I am not sure of it, but just wanted to say, try reading ../driver/input , also check out which driver is loaded for your kernel, try lsmod , In my
      Message 2 of 6 , Mar 2, 2003
        Hi !
        Well I am not sure of it, but just wanted to say, try reading "../driver/input", also check out which driver is loaded for your kernel, try "lsmod", In my case it shows "mousedev" and on running "locate" I found them in .."/lib/modules/kernel/driver/input/mousedev.o", so I guess compile your own driver rename it to mousedev.o put it in this place, and reboot the system ?, or "rmmod moudedev" and "insmod mousedev" .
        Well about the request region !, I think in open, first check if it's free then request, release it in release/close.
        I hope this'll halp you.
        Regards
        Vignesh Baliga

        >>> pleaseinform2000@... 03/01/03 08:06PM >>>

        hello friend,
        you have spoken about the device
        normally mknod is used after inserting a driver.
        i want to know which .c file was infact inserted.
        where is the request for region made !!!
        for a mouse with interface as PS/2 and interrupt line 12
        which is the file from where one has to start reading the kernel
        to write one's own mouse and keyboard driver
        from /usr/src/linux-2.4.7-10/drivers is it ??
        input.c , mousedev.c , mouse_ps2.c , keybdev.c ,pc_keyb.c
        or is it any other !!!
        tell me the starting file
        let me work from there
        with regards,
        anish <anishg3@...> wrote:If u want to use ur mouse driver, make a soft link to /dev/mouse, as I have seen in mine m/c it is /dev/mouse->psaux,
        you do ln -s /dev/mouse /dev/my_mouse_driver.
        and then restart X ctrl+alt+Backspace.
        I hope that shoul work.

        Regards,
        Anish
        ----- Original Message -----
        From: msudipto2002 <msudipto2002@...>
        To: linux-bangalore-programming@yahoogroups.com
        Sent: Tuesday, February 25, 2003 10:47 AM
        Subject: [blug-prog] Linux Device Driver


        I have written a small module of mouse driver in linux. I have loaded
        the module with the help of insmod. The module is successfully
        loaded. Now how can i test my mouse device driver? Can anyone tell me
        exactly what are the steps to be followed after loading a mouse
        module. How to make our driver the default one?How to test our own
        mouse driver?



        Yahoo! Groups Sponsor
        ADVERTISEMENT





        ---------------------------------------------------------------
        This is the programming list of the Bangalore Linux Users Group
        ---------------------------------------------------------------
        Go to http://linux-bangalore.org for more information
        about us, as well as our other mailing lists

        Before you post to this list, please read
        http://linux-bangalore.org/articles/smart-questions.php


        Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



        [Non-text portions of this message have been removed]



        Yahoo! Groups SponsorADVERTISEMENT


        ---------------------------------------------------------------
        This is the programming list of the Bangalore Linux Users Group
        ---------------------------------------------------------------
        Go to http://linux-bangalore.org for more information
        about us, as well as our other mailing lists

        Before you post to this list, please read
        http://linux-bangalore.org/articles/smart-questions.php


        Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

        Catch all the cricket action. Download Yahoo! Score tracker

        [Non-text portions of this message have been removed]




        ---------------------------------------------------------------
        This is the programming list of the Bangalore Linux Users Group
        ---------------------------------------------------------------
        Go to http://linux-bangalore.org for more information
        about us, as well as our other mailing lists

        Before you post to this list, please read
        http://linux-bangalore.org/articles/smart-questions.php


        Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
      • maneesh menon
        hello Vigneshwar, i tried it, but in my pc i have binfmt_misc in /proc/modules when ther is netrwoking and all options icluded , but without it is something
        Message 3 of 6 , Mar 3, 2003
          hello Vigneshwar,
          i tried it, but in my pc i have binfmt_misc in /proc/modules when ther is
          netrwoking and all options icluded , but without it is something else
          moreover in redhat 6.1 there is no module at all in /proc/modules.
          Infact what actually screwd me was when i was told that for
          PS/2 interface there is no module loaded at all for mouse. GPM handles it all
          Which is the kernel version in your pc and mouse interface.
          please keep in touch
          with regards,
          maneesh

          Vigneshwar Baliga <vigneshwarb@...> wrote:Hi !
          Well I am not sure of it, but just wanted to say, try reading "../driver/input", also check out which driver is loaded for your kernel, try "lsmod", In my case it shows "mousedev" and on running "locate" I found them in .."/lib/modules/kernel/driver/input/mousedev.o", so I guess compile your own driver rename it to mousedev.o put it in this place, and reboot the system ?, or "rmmod moudedev" and "insmod mousedev" .
          Well about the request region !, I think in open, first check if it's free then request, release it in release/close.
          I hope this'll halp you.
          Regards
          Vignesh Baliga

          >>> pleaseinform2000@... 03/01/03 08:06PM >>>

          hello friend,
          you have spoken about the device
          normally mknod is used after inserting a driver.
          i want to know which .c file was infact inserted.
          where is the request for region made !!!
          for a mouse with interface as PS/2 and interrupt line 12
          which is the file from where one has to start reading the kernel
          to write one's own mouse and keyboard driver
          from /usr/src/linux-2.4.7-10/drivers is it ??
          input.c , mousedev.c , mouse_ps2.c , keybdev.c ,pc_keyb.c
          or is it any other !!!
          tell me the starting file
          let me work from there
          with regards,
          anish <anishg3@...> wrote:If u want to use ur mouse driver, make a soft link to /dev/mouse, as I have seen in mine m/c it is /dev/mouse->psaux,
          you do ln -s /dev/mouse /dev/my_mouse_driver.
          and then restart X ctrl+alt+Backspace.
          I hope that shoul work.

          Regards,
          Anish
          ----- Original Message -----
          From: msudipto2002 <msudipto2002@...>
          To: linux-bangalore-programming@yahoogroups.com
          Sent: Tuesday, February 25, 2003 10:47 AM
          Subject: [blug-prog] Linux Device Driver


          I have written a small module of mouse driver in linux. I have loaded
          the module with the help of insmod. The module is successfully
          loaded. Now how can i test my mouse device driver? Can anyone tell me
          exactly what are the steps to be followed after loading a mouse
          module. How to make our driver the default one?How to test our own
          mouse driver?



          Yahoo! Groups Sponsor
          ADVERTISEMENT





          ---------------------------------------------------------------
          This is the programming list of the Bangalore Linux Users Group
          ---------------------------------------------------------------
          Go to http://linux-bangalore.org for more information
          about us, as well as our other mailing lists

          Before you post to this list, please read
          http://linux-bangalore.org/articles/smart-questions.php


          Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



          [Non-text portions of this message have been removed]



          Yahoo! Groups SponsorADVERTISEMENT


          ---------------------------------------------------------------
          This is the programming list of the Bangalore Linux Users Group
          ---------------------------------------------------------------
          Go to http://linux-bangalore.org for more information
          about us, as well as our other mailing lists

          Before you post to this list, please read
          http://linux-bangalore.org/articles/smart-questions.php


          Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

          Catch all the cricket action. Download Yahoo! Score tracker

          [Non-text portions of this message have been removed]




          ---------------------------------------------------------------
          This is the programming list of the Bangalore Linux Users Group
          ---------------------------------------------------------------
          Go to http://linux-bangalore.org for more information
          about us, as well as our other mailing lists

          Before you post to this list, please read
          http://linux-bangalore.org/articles/smart-questions.php


          Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/



          Yahoo! Groups SponsorADVERTISEMENT


          ---------------------------------------------------------------
          This is the programming list of the Bangalore Linux Users Group
          ---------------------------------------------------------------
          Go to http://linux-bangalore.org for more information
          about us, as well as our other mailing lists

          Before you post to this list, please read
          http://linux-bangalore.org/articles/smart-questions.php


          Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

          Catch all the cricket action. Download Yahoo! Score tracker

          [Non-text portions of this message have been removed]
        • Vigneshwar Baliga
          Hi ! Well the module you discribed binfmt_misc is a utility (may be I am wrong) that helps in executing executable of other binary format or so, I mean
          Message 4 of 6 , Mar 3, 2003
            Hi !
            Well the module you discribed "binfmt_misc" is a utility (may be I am wrong) that helps in executing executable of other binary format or so, I mean ..some thing like using jvm for java .. (I am not sure)
            Well , I have not worked on Redhat 6.1, but I guess it should show you some modules loaded (this feture is there at least in 2.2.x kernel). Mine is 2.4.18-14 redhat 8.
            All I know about input devices is that, there is a module which registers as charector device (I believe, dont remember now), and provides the feture to input devices. it's input.c, should be in ".../derivers/input", in source tree. all the input devices register with it.
            But I am also a bit confused (Sorry), as I removed the mousedev and input module (rmmod), and my mouse seems to be working !, I dint try this in GUI/X-server.
            I'll try in GUI mode and let you know
            bye...
            Baliga

            >>> pleaseinform2000@... 03/03/03 02:52PM >>>

            hello Vigneshwar,
            i tried it, but in my pc i have binfmt_misc in /proc/modules when ther is
            netrwoking and all options icluded , but without it is something else
            moreover in redhat 6.1 there is no module at all in /proc/modules.
            Infact what actually screwd me was when i was told that for
            PS/2 interface there is no module loaded at all for mouse. GPM handles it all
            Which is the kernel version in your pc and mouse interface.
            please keep in touch
            with regards,
            maneesh

            Vigneshwar Baliga <vigneshwarb@...> wrote:Hi !
            Well I am not sure of it, but just wanted to say, try reading "../driver/input", also check out which driver is loaded for your kernel, try "lsmod", In my case it shows "mousedev" and on running "locate" I found them in .."/lib/modules/kernel/driver/input/mousedev.o", so I guess compile your own driver rename it to mousedev.o put it in this place, and reboot the system ?, or "rmmod moudedev" and "insmod mousedev" .
            Well about the request region !, I think in open, first check if it's free then request, release it in release/close.
            I hope this'll halp you.
            Regards
            Vignesh Baliga

            >>> pleaseinform2000@... 03/01/03 08:06PM >>>

            hello friend,
            you have spoken about the device
            normally mknod is used after inserting a driver.
            i want to know which .c file was infact inserted.
            where is the request for region made !!!
            for a mouse with interface as PS/2 and interrupt line 12
            which is the file from where one has to start reading the kernel
            to write one's own mouse and keyboard driver
            from /usr/src/linux-2.4.7-10/drivers is it ??
            input.c , mousedev.c , mouse_ps2.c , keybdev.c ,pc_keyb.c
            or is it any other !!!
            tell me the starting file
            let me work from there
            with regards,
            anish <anishg3@...> wrote:If u want to use ur mouse driver, make a soft link to /dev/mouse, as I have seen in mine m/c it is /dev/mouse->psaux,
            you do ln -s /dev/mouse /dev/my_mouse_driver.
            and then restart X ctrl+alt+Backspace.
            I hope that shoul work.

            Regards,
            Anish
            ----- Original Message -----
            From: msudipto2002 <msudipto2002@...>
            To: linux-bangalore-programming@yahoogroups.com
            Sent: Tuesday, February 25, 2003 10:47 AM
            Subject: [blug-prog] Linux Device Driver


            I have written a small module of mouse driver in linux. I have loaded
            the module with the help of insmod. The module is successfully
            loaded. Now how can i test my mouse device driver? Can anyone tell me
            exactly what are the steps to be followed after loading a mouse
            module. How to make our driver the default one?How to test our own
            mouse driver?



            Yahoo! Groups Sponsor
            ADVERTISEMENT





            ---------------------------------------------------------------
            This is the programming list of the Bangalore Linux Users Group
            ---------------------------------------------------------------
            Go to http://linux-bangalore.org for more information
            about us, as well as our other mailing lists

            Before you post to this list, please read
            http://linux-bangalore.org/articles/smart-questions.php


            Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



            [Non-text portions of this message have been removed]



            Yahoo! Groups SponsorADVERTISEMENT


            ---------------------------------------------------------------
            This is the programming list of the Bangalore Linux Users Group
            ---------------------------------------------------------------
            Go to http://linux-bangalore.org for more information
            about us, as well as our other mailing lists

            Before you post to this list, please read
            http://linux-bangalore.org/articles/smart-questions.php


            Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

            Catch all the cricket action. Download Yahoo! Score tracker

            [Non-text portions of this message have been removed]




            ---------------------------------------------------------------
            This is the programming list of the Bangalore Linux Users Group
            ---------------------------------------------------------------
            Go to http://linux-bangalore.org for more information
            about us, as well as our other mailing lists

            Before you post to this list, please read
            http://linux-bangalore.org/articles/smart-questions.php


            Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/



            Yahoo! Groups SponsorADVERTISEMENT


            ---------------------------------------------------------------
            This is the programming list of the Bangalore Linux Users Group
            ---------------------------------------------------------------
            Go to http://linux-bangalore.org for more information
            about us, as well as our other mailing lists

            Before you post to this list, please read
            http://linux-bangalore.org/articles/smart-questions.php


            Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

            Catch all the cricket action. Download Yahoo! Score tracker

            [Non-text portions of this message have been removed]




            ---------------------------------------------------------------
            This is the programming list of the Bangalore Linux Users Group
            ---------------------------------------------------------------
            Go to http://linux-bangalore.org for more information
            about us, as well as our other mailing lists

            Before you post to this list, please read
            http://linux-bangalore.org/articles/smart-questions.php


            Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
          • Vigneshwar Baliga
            Hi maneesh !, As I said, I am not much aware of the input device concept, and the rethat 6.1, but I just can tell you what happened when I tried on my PC (PS/2
            Message 5 of 6 , Mar 4, 2003
              Hi maneesh !,
              As I said, I am not much aware of the input device concept, and the rethat 6.1, but I just can tell you what happened when I tried on my PC (PS/2 Mouse redhat8, 2.4.18-14 kernel)
              I compiled the mousedev.c file with my comments in "event", "read", and "poll", then I placed it in the /lib/modules/2.x.x/kernel/drivers/input/ , after that I started the Xserver (startx) , at start x, the progm reloads the input.o and mousedev.o if not present (lsmod). So this time My driver was selected and after that when ever the mouse was moved the control used to go to "poll" entry point. the "read" entry point was called few number of times , but only when the xserver was starting.
              Well , I dont have a 2.2.x kernel to check out what you said, or to test there..., Ya, also just see in /lib/modules/2.x.x/kernel/drivers/ , there check if there is any driver that sounds like some human input class driver, or input class, or mouse ? :-)
              if So try messing with it(*.c ), (ofcourse keep the back up of it ).
              bye..
              Vignesh Baliga



              >>> pleaseinform2000@... 03/03/03 02:52PM >>>

              hello Vigneshwar,
              i tried it, but in my pc i have binfmt_misc in /proc/modules when ther is
              netrwoking and all options icluded , but without it is something else
              moreover in redhat 6.1 there is no module at all in /proc/modules.
              Infact what actually screwd me was when i was told that for
              PS/2 interface there is no module loaded at all for mouse. GPM handles it all
              Which is the kernel version in your pc and mouse interface.
              please keep in touch
              with regards,
              maneesh

              Vigneshwar Baliga <vigneshwarb@...> wrote:Hi !
              Well I am not sure of it, but just wanted to say, try reading "../driver/input", also check out which driver is loaded for your kernel, try "lsmod", In my case it shows "mousedev" and on running "locate" I found them in .."/lib/modules/kernel/driver/input/mousedev.o", so I guess compile your own driver rename it to mousedev.o put it in this place, and reboot the system ?, or "rmmod moudedev" and "insmod mousedev" .
              Well about the request region !, I think in open, first check if it's free then request, release it in release/close.
              I hope this'll halp you.
              Regards
              Vignesh Baliga

              >>> pleaseinform2000@... 03/01/03 08:06PM >>>

              hello friend,
              you have spoken about the device
              normally mknod is used after inserting a driver.
              i want to know which .c file was infact inserted.
              where is the request for region made !!!
              for a mouse with interface as PS/2 and interrupt line 12
              which is the file from where one has to start reading the kernel
              to write one's own mouse and keyboard driver
              from /usr/src/linux-2.4.7-10/drivers is it ??
              input.c , mousedev.c , mouse_ps2.c , keybdev.c ,pc_keyb.c
              or is it any other !!!
              tell me the starting file
              let me work from there
              with regards,
              anish <anishg3@...> wrote:If u want to use ur mouse driver, make a soft link to /dev/mouse, as I have seen in mine m/c it is /dev/mouse->psaux,
              you do ln -s /dev/mouse /dev/my_mouse_driver.
              and then restart X ctrl+alt+Backspace.
              I hope that shoul work.

              Regards,
              Anish
              ----- Original Message -----
              From: msudipto2002 <msudipto2002@...>
              To: linux-bangalore-programming@yahoogroups.com
              Sent: Tuesday, February 25, 2003 10:47 AM
              Subject: [blug-prog] Linux Device Driver


              I have written a small module of mouse driver in linux. I have loaded
              the module with the help of insmod. The module is successfully
              loaded. Now how can i test my mouse device driver? Can anyone tell me
              exactly what are the steps to be followed after loading a mouse
              module. How to make our driver the default one?How to test our own
              mouse driver?



              Yahoo! Groups Sponsor
              ADVERTISEMENT





              ---------------------------------------------------------------
              This is the programming list of the Bangalore Linux Users Group
              ---------------------------------------------------------------
              Go to http://linux-bangalore.org for more information
              about us, as well as our other mailing lists

              Before you post to this list, please read
              http://linux-bangalore.org/articles/smart-questions.php


              Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



              [Non-text portions of this message have been removed]



              Yahoo! Groups SponsorADVERTISEMENT


              ---------------------------------------------------------------
              This is the programming list of the Bangalore Linux Users Group
              ---------------------------------------------------------------
              Go to http://linux-bangalore.org for more information
              about us, as well as our other mailing lists

              Before you post to this list, please read
              http://linux-bangalore.org/articles/smart-questions.php


              Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

              Catch all the cricket action. Download Yahoo! Score tracker

              [Non-text portions of this message have been removed]




              ---------------------------------------------------------------
              This is the programming list of the Bangalore Linux Users Group
              ---------------------------------------------------------------
              Go to http://linux-bangalore.org for more information
              about us, as well as our other mailing lists

              Before you post to this list, please read
              http://linux-bangalore.org/articles/smart-questions.php


              Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/



              Yahoo! Groups SponsorADVERTISEMENT


              ---------------------------------------------------------------
              This is the programming list of the Bangalore Linux Users Group
              ---------------------------------------------------------------
              Go to http://linux-bangalore.org for more information
              about us, as well as our other mailing lists

              Before you post to this list, please read
              http://linux-bangalore.org/articles/smart-questions.php


              Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

              Catch all the cricket action. Download Yahoo! Score tracker

              [Non-text portions of this message have been removed]




              ---------------------------------------------------------------
              This is the programming list of the Bangalore Linux Users Group
              ---------------------------------------------------------------
              Go to http://linux-bangalore.orgevice Driver


              I hav for more information
              about us, as well as our other mailing lists

              Before you post to this list, please read
              http://linux-bangalore.org/articles/smart-questions.php


              Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
            Your message has been successfully submitted and would be delivered to recipients shortly.