Re: [merged mm-stable] x86-module-prepare-module-loading-for-rox-allocations-of-text.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Peter,

On Thu, Dec 05, 2024 at 09:41:28AM +0100, Peter Zijlstra wrote:
> On Wed, Nov 06, 2024 at 08:50:41AM +0200, Mike Rapoport wrote:
> 
> Anyway, while noodling with all that, I think there's a fairly
> fundamental error in all of this. The mem->rw_copy should not be a whole
> second allocation, it should be a (page granular) RW alias of the
> (large) ROX map.

I've made mem->rw_copy an allocation because Andy raised a concern [1] that
we'll have an executable mapping of semi-formed code. 
With an actual copy rather than an alias the ROX pages contain invalid
instructions up to the point we're through with relocations and
alternatives patching and the actual code appears in ROX mappings in one
go.
 
[1] https://lore.kernel.org/all/a17c65c6-863f-4026-9c6f-a04b659e9ab4@xxxxxxxxxxxxxxxx

> That also gets rid of that whole copy operation.
> 
> I'm having to chase a few regressions of my own first, but after that
> I'll look at reworking all this.

-- 
Sincerely yours,
Mike.




[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux