Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp1002535ybh; Tue, 10 Mar 2020 12:31:24 -0700 (PDT) X-Google-Smtp-Source: ADFU+vsJ5WCOW/nrKqUo9fDbQBRZ85pHvKsdJAUwRPjBsdykoWAwiBewl2dvCDlNrlZBq1Im0xTj X-Received: by 2002:a05:6830:18d4:: with SMTP id v20mr7931637ote.23.1583868684134; Tue, 10 Mar 2020 12:31:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1583868684; cv=none; d=google.com; s=arc-20160816; b=ZtHPUxVOPxaccoaiGAknM67ZLmYOTFAsdLFop9Onxx7P0i70neLEDCMXhjwsGMxsSR qNudZ0J4kDxRD+dSCJ9ahaMddXMbeGaPyJM+pukYcP5XuIgRCi1cRwgoeZFBTYno00XM TMnhiA3a6swUTx2zcYYWfa0L76ut6fkE5xiFml0SanTlmapz/Zx8gb7O1N0HZoXk+0zv AlVTFR3xCieYOV5T+RrByVariyFQrb4grJDqKeBmdM0V9o1UtS9Sn75rBuCaCGCtof3p w9Q9e5czGL5SDa7xQZAtqAVfGoJgF3tTzXeDgX3WFMj8508ey4wMX8WLssv8c/4N0ulM 4cuA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=AJRSlX8ACsNJYHeYADgE5H8uhXcF0mJHjX5CwOONp+U=; b=jKMSMB34s8UgA2KXcsK68JcV9NSzuuIMYWgQyTn4I4261QRnkTDBuh0QScQwfrp6IN Of5aCe+Y1dHIc4La6akjzaJQigQCYDH8fc6BfMAhkf0Of7GjtcFXPrpHOF6NXuUuUCzn xsZKvjJXEwrNSgloIn2upS4UdqRZDxQn7znaRsWlDpSwYy7Uo7vR1LthXiBs8NsKGgyo OA6QVVdthGDdmdUKIZjSxGmIWvDNzXP87rqcsa4G13HSJp2q4W3gyclXXRh1fChCS3KZ UEGFUwQrx56fUQFBKbJcUaCrEmv8KwE4g9ud0PsiQdQ7wR5HzLOr3WmwydJn0kgq6g7e vRoQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=tNa2jovN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a21si4553609otk.277.2020.03.10.12.31.12; Tue, 10 Mar 2020 12:31:24 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=tNa2jovN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727437AbgCJTas (ORCPT + 99 others); Tue, 10 Mar 2020 15:30:48 -0400 Received: from mail-pl1-f195.google.com ([209.85.214.195]:40974 "EHLO mail-pl1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726729AbgCJTas (ORCPT ); Tue, 10 Mar 2020 15:30:48 -0400 Received: by mail-pl1-f195.google.com with SMTP id t14so5834709plr.8 for ; Tue, 10 Mar 2020 12:30:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=AJRSlX8ACsNJYHeYADgE5H8uhXcF0mJHjX5CwOONp+U=; b=tNa2jovN2/9sEj+6L+LwQ89bUm6qQeL5msJv6lU9KS/ceeZ43FUB09Flmsn6bgDHj4 aAZ1SXH+4BR3x+lnlFZj+jZ4zGtboFb18SrT62j0SZ/0dzyG4C3e8vqirT3qBl+vQyFY FmhEfWDKOmwrZAbmVMS89aVn9svg7eNR81bzxT1otZKw7VXyHPfGicxpnBlFOj+tLr3E oPBY4Y/Zd97bn7KYmCDKZJ3hekzFzeu2r+vXpUsxmHsjV9c2f+eH3NBdTzCO2HkVBdqT z3Nt7KOgDUJ3b5vWXwF5iZzGRN7QlM583joEbUXkF7mdmeWDZbrljNYf8dGuJmwiiI++ H2Qw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=AJRSlX8ACsNJYHeYADgE5H8uhXcF0mJHjX5CwOONp+U=; b=GWhiNF/WuhgClKV3kQ+ncDbIm0846DlRCrW9VKP1WKxdQwUIzmqpK/xPS/ZSnxN08c Kww1fwGrpPvHSBA3PDAzmZqcA24mcguaNSQz7OiFkcwzBQDDIzIEMlXsE18kqbD8CWhH BBJF3hszSPa1kNKeMEvpEIUfklr3Z2Wk5exeCQdYBxvaaekIjZVSKLqky3lkKlhs/JLj MyACmVSXyOX7q7dXan88rNMzO5+O+wxNNcnfVEUP10CYS7ESt8uwwYPwA4bcv6asgxBp xY0OZxE7fQOGCWwQOD7z6+PNoonL6FbHAc2QNa6Q7F0cQ7btwdCVI+GLsWN+257zkMsO pNOw== X-Gm-Message-State: ANhLgQ2JHs/8lpvfquyS08pQ/7RAOJl/22iHyGsrTa+4b2vNflafJlyy Wh7cEJdCUl+rDw6ETrru/LX/ug== X-Received: by 2002:a17:90b:4903:: with SMTP id kr3mr3246307pjb.3.1583868646154; Tue, 10 Mar 2020 12:30:46 -0700 (PDT) Received: from yoga (104-188-17-28.lightspeed.sndgca.sbcglobal.net. [104.188.17.28]) by smtp.gmail.com with ESMTPSA id 19sm27050061pfn.30.2020.03.10.12.30.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Mar 2020 12:30:45 -0700 (PDT) Date: Tue, 10 Mar 2020 12:30:42 -0700 From: Bjorn Andersson To: Cl?ment Leger Cc: Mathieu Poirier , Ohad Ben-Cohen , Jonathan Corbet , Shawn Guo , Sascha Hauer , linux-remoteproc , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Andy Gross , Patrice Chotard , linux-doc , linux-kernel , linux-arm-kernel , linux-arm-msm , Arnaud Pouliquen , Loic PALLARDY , s-anna Subject: Re: [PATCH v5 5/8] remoteproc: Rename rproc_elf_sanity_check for elf32 Message-ID: <20200310193042.GK264362@yoga> References: <20200210162209.23149-1-cleger@kalray.eu> <20200302093902.27849-1-cleger@kalray.eu> <20200302093902.27849-6-cleger@kalray.eu> <20200302231342.GE262924@yoga> <482678048.7666348.1583222551942.JavaMail.zimbra@kalray.eu> <20200310000005.GF14744@builder> <20200310152031.GA25781@xps15> <371773363.9138477.1583854699708.JavaMail.zimbra@kalray.eu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <371773363.9138477.1583854699708.JavaMail.zimbra@kalray.eu> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue 10 Mar 08:38 PDT 2020, Cl?ment Leger wrote: > Hi Mathieu, > > ----- On 10 Mar, 2020, at 16:20, Mathieu Poirier mathieu.poirier@linaro.org wrote: > > > On Mon, Mar 09, 2020 at 05:00:05PM -0700, Bjorn Andersson wrote: > >> On Tue 03 Mar 00:02 PST 2020, Cl?ment Leger wrote: > >> > >> > Hi Bjorn, > >> > > >> > ----- On 3 Mar, 2020, at 00:13, Bjorn Andersson bjorn.andersson@linaro.org > >> > wrote: > >> > > >> > > On Mon 02 Mar 01:38 PST 2020, Clement Leger wrote: > >> > > > >> > >> Since this function will be modified to support both elf32 and elf64, > >> > >> rename the existing one to elf32 (which is the only supported format > >> > >> at the moment). This will allow not to introduce possible side effect > >> > >> when adding elf64 support (ie: all backends will still support only > >> > >> elf32 if not requested explicitely using rproc_elf_sanity_check). > >> > >> > >> > > > >> > > Is there a reason for preventing ELF64 binaries be loaded? > >> > > >> > I decided to go this way to let driver maintainer decide if they want > >> > to support elf64 to avoid problems with 64bits addresses/sizes which do > >> > not fit in their native type (size_t for instance). This is probably > >> > not going to happen and there are additionnal checks before calling > >> > rproc_da_to_va. And addresses should be filtered by rproc_da_to_va. > >> > So, actually it seems there is no reason to forbid supporting elf32/64 > >> > for all drivers. > >> > > >> > >> I was hoping to hear some additional feedback on this from others. > > > > I didn't follow up on this one because I agreed with your assesment and didn't > > think it was needed. > > > > Simply put I would rather see rproc_elf_sanity_check() gain support for elf64 > > and let the platform code decide what to do with format they don't support > > rather than spinning a new function. > > > >> > >> I've merge the patch as is, but think it would be nice to clean this up > >> and just have the driver ignore if fed a 32 or 64-elf. > > > > It would be really nice to see this cleaned up in time for the coming merge > > window... > > I could have sent a V7, but Bjorn was faster than my comment ;) I figured it had been maturing on the list long enough and expected the cleanup to be a nice incremental patch. > Bjorn, Is there any way to revert that or it's already pushed ? > I already have a clean V7. > Please base your changes on what's in rproc-next (and today's linux-next). Thank you, Bjorn