From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CF6F5C7EE2A for ; Tue, 23 May 2023 09:13:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235944AbjEWJN7 (ORCPT ); Tue, 23 May 2023 05:13:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42958 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236199AbjEWJNx (ORCPT ); Tue, 23 May 2023 05:13:53 -0400 Received: from elvis.franken.de (elvis.franken.de [193.175.24.41]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 0BE9713E; Tue, 23 May 2023 02:13:46 -0700 (PDT) Received: from uucp (helo=alpha) by elvis.franken.de with local-bsmtp (Exim 3.36 #1) id 1q1O5K-0007MY-00; Tue, 23 May 2023 11:13:38 +0200 Received: by alpha.franken.de (Postfix, from userid 1000) id D9E9CC02E5; Tue, 23 May 2023 11:05:56 +0200 (CEST) Date: Tue, 23 May 2023 11:05:56 +0200 From: Thomas Bogendoerfer To: Liviu Dudau Cc: Paul Burton , John Crispin , =?utf-8?B?QXLEsW7DpyDDnE5BTA==?= , Sergio Paracuellos , linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mips: Move initrd_start check after initrd address sanitisation. Message-ID: <20230523090556.GA9484@alpha.franken.de> References: <20230509172921.295700-1-liviu@dudau.co.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230509172921.295700-1-liviu@dudau.co.uk> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, May 09, 2023 at 06:29:21PM +0100, Liviu Dudau wrote: > PAGE_OFFSET is technically a virtual address so when checking the value of > initrd_start against it we should make sure that it has been sanitised from > the values passed by the bootloader. Without this change, even with a bootloader > that passes correct addresses for an initrd, we are failing to load it on MT7621 > boards, for example. > > Signed-off-by: Liviu Dudau > --- > arch/mips/kernel/setup.c | 9 +++++---- > 1 file changed, 5 insertions(+), 4 deletions(-) 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 ]