Received: by 10.213.65.68 with SMTP id h4csp458292imn; Fri, 16 Mar 2018 08:22:03 -0700 (PDT) X-Google-Smtp-Source: AG47ELthIIqGoTiFU+7ESY1Nz19qH0wrXsOWb4aOZeUG2d4wQUMixnjDxLmaXSsfD+T/eaXu00qt X-Received: by 10.98.74.67 with SMTP id x64mr1882651pfa.135.1521213723034; Fri, 16 Mar 2018 08:22:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521213723; cv=none; d=google.com; s=arc-20160816; b=KOW/jCA4AHIb2QTbKoNVemtWQyYyrYmolEmAzBPrXzlgFmwk830UOWiPLXb1uYWkmv OBx1BAwiJtsfTAPlyFGI23E760GsugLRW8/u44J4oIG0HXoKnxr64tLDdvWbAvAIozTO tz2dTKh/z8jVpoNCy4sF3iXtdxFJlxTBEHV7aA092isdAsc1FaX7a9dCxmi87ljtF39J caKc3/wXVR7ye/YQYmQ2DpO4G3Mc11BtAJZ5iyFuHiW4VAzlosPpYlbLBoMW+L6QYHhm 0EkQU3Ohk2FOnoN1+VLDfumuzQ9g0p2acCP56bm1VlhU/rizHKl8fwsJyqZ7Sd95vIDG 3b8A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=JCwv8I/gw3K5plZfOaiIO2bjwDucjV20cNbYv4Zyv5A=; b=Q/rUlcYdIhF/IWwr7lhGR+9aT2xlmG0o9gy66CmPhjQwyhfIM4Osq2WbxPK6pOw6iI rAZK0wHwSNecACzRJKX6S93oSmwy3Q6RYp03OftVmDQPmR/gfLd6Vp5CGxQ2urDu+kLx qmJzsTeRcVyUb3piwdVU96SX/fX+rcMV6mychvBrv6Oywr4oY4te5mo4HuOEs6F89XNW D5fOm0uQj2OizQAnLmKy97a30+vMWVXbxOAHMcI3pYGraqCZlVtbQU2LRR+Oj5Pgscoe jfhQ2bImwIQE6+buOWryoCmmiq4+BmL781UhvnqJdJMa3diI1qm33oS2Vub4sXoOtWp2 XWLg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@lechnology.com header.s=default header.b=cqgQ+nfR; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i11-v6si6444095plk.139.2018.03.16.08.21.48; Fri, 16 Mar 2018 08:22:03 -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=fail header.i=@lechnology.com header.s=default header.b=cqgQ+nfR; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753371AbeCPPUi (ORCPT + 99 others); Fri, 16 Mar 2018 11:20:38 -0400 Received: from vern.gendns.com ([206.190.152.46]:57229 "EHLO vern.gendns.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753340AbeCPPUg (ORCPT ); Fri, 16 Mar 2018 11:20:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lechnology.com; s=default; h=Content-Transfer-Encoding:Content-Type: In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To:Subject:Sender :Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=JCwv8I/gw3K5plZfOaiIO2bjwDucjV20cNbYv4Zyv5A=; b=cqgQ+nfRUfu2XoIshg6QWSGSdP twgDHT1ZmZxrmdB8nzBawpHPELEIsztqQW/hZ5at1F6yjXcoBqZPkY1GpNR9d/cSWfqnN72Ngt6nk yF1Yiq04/wCt1yiLnJFAgmmVBUHUbOENF1FgUB4A4vzWsSBDIqeVWvMrxOw2RywUlg+ztau5IdxfD O1KdbmFRhusjUXq6jmo3HsCgZG5ex4VgCFSmKaJLnJRvC6xilRAASl15ywa8KpgbHXdD0dfAuPkzX 57IzoIMR8TTwNVpYaMKONt3o5W+dBXlMe4HpNmSL8njIhBsyz1lA2fL2Lk5zfH8sEiGGPC2o2Xv4C TqdmTcdg==; Received: from 108-198-5-147.lightspeed.okcbok.sbcglobal.net ([108.198.5.147]:52720 helo=[192.168.0.134]) by vern.gendns.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128) (Exim 4.89_1) (envelope-from ) id 1ewr7q-000cqG-VR; Fri, 16 Mar 2018 11:18:35 -0400 Subject: Re: [PATCH] ARM: davinci: DA8XX: fix oops in USB PHY driver due to stack allocated platform platform_data To: Sekhar Nori , linux-arm-kernel@lists.infradead.org Cc: Kevin Hilman , Bartosz Golaszewski , linux-kernel@vger.kernel.org References: <1521136976-32730-1-git-send-email-david@lechnology.com> <382a269a-f486-8c1a-23b2-9620a01a073c@ti.com> From: David Lechner Message-ID: Date: Fri, 16 Mar 2018 10:20:36 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <382a269a-f486-8c1a-23b2-9620a01a073c@ti.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - vern.gendns.com X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - lechnology.com X-Get-Message-Sender-Via: vern.gendns.com: authenticated_id: davidmain+lechnology.com/only user confirmed/virtual account not confirmed X-Authenticated-Sender: vern.gendns.com: davidmain@lechnology.com X-Source: X-Source-Args: X-Source-Dir: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 03/16/2018 05:17 AM, Sekhar Nori wrote: > On Thursday 15 March 2018 11:32 PM, David Lechner wrote: >> This fixes a possible kernel oops due to using stack allocated platform >> data for the USB PHY driver on DA8XX devices. If the platform device >> probe is deferred, then we get a corrupt pointer for the platform data. >> >> We now use a global static struct for the platform data so that the >> platform data pointer does not get written over. >> >> Tested on OMAP-L138 LCDK board using legacy board file. > > Oops. That should have been caught in review. > >> >> Fixes: 9b504750923cb ("ARM: davinci: da8xx: Add USB PHY platform device") > > The offending commit seems to be bdec5a6b5789 ("ARM: da8xx: use platform > data for CFGCHIP syscon regmap") in my tree which should be in > linux-next. I don't think we have this issue in mainline. Right? You are right. I'm not sure how I got that older commit. The issue is not in mainline yet. > >> Signed-off-by: David Lechner > > Thanks, > Sekhar >