[Toybox] [PATCH] rmmod: various fixes.

enh enh at google.com
Fri Sep 10 16:10:03 PDT 2021


My original intent was to just get rid of the meaningless O_EXCL, which
isn't used by the kernel, after noticing that it's passed here but not
in modprobe's module removal code.

But then I noticed that other rmmod implementations allow you to pass a
list of modules, not just one (whereas we were ignoring all but the
first). And that the help syntax was wrong. And that strend() lets us
write the code to remove the ".ko" suffix a bit nicer.

And of course, switch to the FLAG() macro.
---
 toys/other/rmmod.c | 35 ++++++++++++++++-------------------
 1 file changed, 16 insertions(+), 19 deletions(-)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20210910/f99b53fc/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-rmmod-various-fixes.patch
Type: text/x-patch
Size: 2219 bytes
Desc: not available
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20210910/f99b53fc/attachment.bin>


More information about the Toybox mailing list