Giter Site home page Giter Site logo

evdev-mirror's People

Contributors

lwss avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

evdev-mirror's Issues

/dev/input/evdev-mirror not being created?

I dunno this is my first time messing with evdev passthrough...

It compiles just fine, but I dont see the output /dev/input/evdev-mirror so the readexample just returns "Error opening evdev-mirror!(-1)"

`main@root:~/Desktop/evdev-mirror$ sudo make

make -C /lib/modules/5.0.0-31-generic/build M=/home/main/Desktop/evdev-mirror modules
make[1]: Entering directory '/usr/src/linux-headers-5.0.0-31-generic'
CC [M] /home/main/Desktop/evdev-mirror/evdev-mirror.o
/home/main/Desktop/evdev-mirror/evdev-mirror.c: In function ‘mirror_write’:
/home/main/Desktop/evdev-mirror/evdev-mirror.c:180:5: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
struct input_value input;
^~~~~~
/home/main/Desktop/evdev-mirror/evdev-mirror.c: In function ‘startup’:
/home/main/Desktop/evdev-mirror/evdev-mirror.c:216:5: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
int ret = init_hook( &evdev_events_hook );
^~~
Building modules, stage 2.
MODPOST 1 modules
CC /home/main/Desktop/evdev-mirror/evdev-mirror.mod.o
LD [M] /home/main/Desktop/evdev-mirror/evdev-mirror.ko
make[1]: Leaving directory '/usr/src/linux-headers-5.0.0-31-generic'
gcc -o read_example read_example.c
gcc -o write_example write_example.c
main@root:~/Desktop/evdev-mirror$ sudo ./read_example
Error opening evdev-mirror!(-1)
`

Compilation Errors.

Hello, I'm running Ubuntu, Linux Kernel 5.11

if I git clone the repo, and try to make,
I get

/home/xxx/Desktop/evdev/evdev-mirror.c:223:37: error: ‘FTRACE_OPS_FL_RECURSION_SAFE’ undeclared (first use in this function); did you mean ‘FTRACE_OPS_FL_RECURSION’?

So, I followed something that was posted on a different repo of yours, about changing that to FTRACE_OPS_RECURSION, and pt_regs regs to ftrace_regs fregs, and the struct

And now I don't get that error, I can compile it
But I also get the invalid format error now
insmod: ERROR: could not insert module evdev_mirror.ko: Invalid module format

dmesg output after a dmesg clear, then trying to load evdev mirror:
[ 7499.846719] module: x86/modules: Skipping invalid relocation target, existing value is nonzero for type 1, loc 0000000003c96ad2, val ffffffffc06e1310

Am I missing something?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.