2004-06-22 07:59:19

by Zach, Yoav

[permalink] [raw]
Subject: RE: [PATCH] Handle non-readable binfmt_misc executables



>-----Original Message-----
>From: Arjan van de Ven [mailto:[email protected]]
>Sent: Sunday, June 20, 2004 13:50
>To: Zach, Yoav
>Cc: Linux Kernel Mailing List
>Subject: Re: [PATCH] Handle non-readable binfmt_misc executables
>

>
>for one, sys_close, while currently exported, shouldn't be really.
>(it is exported right now for a few drivers that have invalid firmware
>loaders that haven't been converted to the firmware loading framework).

What is the reason that sys_close should not be used by modules ?

>In addition it's way overkill, you created the fd so half the safety
>precautions shouldn/t be needed
>

There are some checks that might be skipped. But I think that calling
sys_close is the right thing to do here, because this way future changes
to the procedure of closing an open fd will not need to be copied to
the recovery code of load_misc_binary. Do you expect there will be any
visible gain in performance if the unnecessary steps are skipped ?
Please
remember this is only recovery code - this is not the main stream
execution.

Thanks,
Yoav.

Yoav Zach
IA-32 Execution Layer
Performance Tools Lab
Intel Corp.