Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf(drm): group dracut_instmods calls #2577

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Nov 30, 2023

  1. perf(drm): group dracut_instmods calls

    This module loops over many bus devices, and calls `dracut_instmods` for each
    one. E.g., on a Lenovo Thinkpad laptop:
    
    ```
    > for i in /sys/bus/{pci/devices,platform/devices,virtio/devices,soc/devices/soc?,vmbus/devices}/*/modalias; do [[ -e $i ]] && [[ -n $(< "$i") ]]  && echo $i; done | wc -l
    79
    ```
    
    Every call to `dracut_instmods` spawns a `dracut-install` process, which in the
    previous example means calling `dracut-install` 79 times using the same
    arguments.
    
    If any call to `dracut-install` fails, dracut continues its execution (even the
    errors are not shown, because it's called with `--silent`). Therefore, let's
    take the contents of all the `modalias` files into an array and call
    `dracut-install` only once, adding also the `-o` argument, so if any of the
    modules cannot be installed, `dracut-install` does not stop.
    aafeijoo-suse committed Nov 30, 2023
    Configuration menu
    Copy the full SHA
    476f0ba View commit details
    Browse the repository at this point in the history