]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
x86/ioperm: Avoid bitmap allocation if no permissions are set
authorThomas Gleixner <tglx@linutronix.de>
Tue, 12 Nov 2019 18:56:19 +0000 (19:56 +0100)
committerThomas Gleixner <tglx@linutronix.de>
Sat, 16 Nov 2019 10:24:01 +0000 (11:24 +0100)
commit32f3bf67ee78332f2caec0984cb9d412cd0a3c23
tree47bf912535016ecb14a1d2f14db0bb8e05256a6e
parentae31cea86ab31f3d2e15d6cc8710754ad7330c9e
x86/ioperm: Avoid bitmap allocation if no permissions are set

If ioperm() is invoked the first time and the @turn_on argument is 0, then
there is no point to allocate a bitmap just to clear permissions which are
not set.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
arch/x86/kernel/ioport.c