lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Tue, 16 Mar 2021 22:59:19 +0100
From:   Thomas Bogendoerfer <tsbogend@...ha.franken.de>
To:     Paul Cercueil <paul@...pouillou.net>
Cc:     od@...c.me, linux-mips@...r.kernel.org,
        linux-kernel@...r.kernel.org,
        Bjørn Mork <bjorn@...k.no>
Subject: Re: [PATCH] MIPS: vmlinux.lds.S: Fix appended dtb not properly
 aligned

On Tue, Mar 16, 2021 at 03:45:15PM +0000, Paul Cercueil wrote:
> Commit 6654111c893f ("MIPS: vmlinux.lds.S: align raw appended dtb to 8
> bytes") changed the alignment from STRUCT_ALIGNMENT bytes to 8 bytes.
> 
> The commit's message makes it sound like it was actually done on
> purpose, but this is not the case. The commit was written when raw
> appended dtb were not aligned at all. The STRUCT_ALIGN() was added a few
> days before, in commit 7a05293af39f ("MIPS: boot/compressed: Copy DTB to
> aligned address"). The true purpose of the commit was not to align
> specifically to 8 bytes, but to make sure that the generated vmlinux'
> size was properly padded to the alignment required for DTBs.
> 
> While the switch to 8-byte alignment worked for vmlinux-appended dtb
> blobs, it broke vmlinuz-appended dtb blobs, as the decompress routine
> moves the blob to a STRUCT_ALIGNMENT aligned address.
> 
> Fix this by changing the raw appended dtb blob alignment from 8 bytes
> back to STRUCT_ALIGNMENT bytes in vmlinux.lds.S.
> 
> Fixes: 6654111c893f ("MIPS: vmlinux.lds.S: align raw appended dtb to 8 bytes")
> Cc: Bjørn Mork <bjorn@...k.no>
> Signed-off-by: Paul Cercueil <paul@...pouillou.net>
> ---
>  arch/mips/kernel/vmlinux.lds.S | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

applied to mips-fixes.

Thomas.

-- 
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea.                                                [ RFC1925, 2.3 ]

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ