From patchwork Fri Nov 22 10:28:07 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 179994 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp36521ilf; Fri, 22 Nov 2019 02:53:17 -0800 (PST) X-Google-Smtp-Source: APXvYqyk08ZR4dAnvNNNKMnM/cUL/P7KDlCODy2cKJp80V+0Lu0rVIxtcWgChNdzNZGfJ2sqlzts X-Received: by 2002:a17:906:ecb8:: with SMTP id qh24mr14499547ejb.174.1574419997838; Fri, 22 Nov 2019 02:53:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574419997; cv=none; d=google.com; s=arc-20160816; b=vUvUihFQK9Ff0vvVum9P7bxAsF08HWfjZ8/UQ96j2A3ep4WgS8qR+g4zUplLiXNt+B LeYYxiC3wQ31EIwTBO3BZ+amHx1kxJrsPwWd8WxS0VfMD65AsHcXK21nof/3vpWbtmiB 2b/JecFNM3x6lYFwfkh+9hSCxPpH7tMoB+hSkESIOflGSWSo+OffeMXy80qCBEzIthzW NpzH8jHKKddfwxJ63wfxdeGMf4E8iC75ja7ULrWanwKQJYeLysS3lieI+hm93e3RTUuw vpeNr1czjlG+DxVVJQ2PomrWg1GqyrPPrSZE4ncijSvlJ3BlpFVQERs2BjWG4NbPjYpr Eaqw== 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:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Z1hxhzWrrpVMJGAyltsxagBPuzbf9a7C+XHXmGvP5jE=; b=bHyfqU90UmBvsw6Wtzc3fSsStPELBksaMjh/hJ03snF2BEyY+dFL2G6NbqgALocHk5 fARedbg9t0Ry+MruwyUW7BfYPRcLX/LQYUVXnwkqYBxBNEMuhZ7n4OGbno3+nu9ZsLm7 27fTDhcT0Avge4FwF7yK5GZo8bWEHVEFk1P0FCW+n/U9/P+F/zY2s5NPLFr2vhWuEV74 BYluzh+jN2u8jAZ/doCOJBfwjClKai9fYcJIExOT71FXvhuPJ3wISqGTQQR78pwr3uKd /j1UpekPV8PO6R9B1WwBEErC/zUKWMtfLO/4Ll2MWdK26fu1lgmSGDcf1ISBIZxRfBR0 JIOA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=c0+0C23w; 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 l40si4842522edb.432.2019.11.22.02.53.17; Fri, 22 Nov 2019 02:53:17 -0800 (PST) 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=@kernel.org header.s=default header.b=c0+0C23w; 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 S1730183AbfKVKxQ (ORCPT + 26 others); Fri, 22 Nov 2019 05:53:16 -0500 Received: from mail.kernel.org ([198.145.29.99]:37502 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730166AbfKVKxM (ORCPT ); Fri, 22 Nov 2019 05:53:12 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 47B6120715; Fri, 22 Nov 2019 10:53:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574419991; bh=aFpAA8wU35EfuFHr6Frbd4f3Et0ExszuYiPWOtiTJRg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=c0+0C23wR6/D7Qw7Zv5udR+wNdhM0d2e+5B1pqURuDrslPrYlxnIRJvsH21t9gtK7 77oe7V430CEW39SRubFJL5hNjSQ7Z3McODfXklAHtokGVnTVNwCKTHSsAhn8h7e5fj f/tsAZjgo4KoByc/zlZurNbmnTbS4Ckijj3xQBxU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Nishanth Menon , Santosh Shilimkar , Stephen Boyd , Sasha Levin Subject: [PATCH 4.14 034/122] clk: keystone: Enable TISCI clocks if K3_ARCH Date: Fri, 22 Nov 2019 11:28:07 +0100 Message-Id: <20191122100749.509920394@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191122100722.177052205@linuxfoundation.org> References: <20191122100722.177052205@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Nishanth Menon [ Upstream commit 2f149e6e14bcb5e581e49307b54aafcd6f74a74f ] K3_ARCH uses TISCI for clocks as well. Enable the same for the driver support. Signed-off-by: Nishanth Menon Acked-by: Santosh Shilimkar Signed-off-by: Stephen Boyd Signed-off-by: Sasha Levin --- drivers/clk/Makefile | 1 + drivers/clk/keystone/Kconfig | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) -- 2.20.1 diff --git a/drivers/clk/Makefile b/drivers/clk/Makefile index f7f761b02beda..8ca03d9d693b0 100644 --- a/drivers/clk/Makefile +++ b/drivers/clk/Makefile @@ -65,6 +65,7 @@ obj-$(CONFIG_ARCH_HISI) += hisilicon/ obj-y += imgtec/ obj-$(CONFIG_ARCH_MXC) += imx/ obj-$(CONFIG_MACH_INGENIC) += ingenic/ +obj-$(CONFIG_ARCH_K3) += keystone/ obj-$(CONFIG_ARCH_KEYSTONE) += keystone/ obj-$(CONFIG_MACH_LOONGSON32) += loongson1/ obj-$(CONFIG_ARCH_MEDIATEK) += mediatek/ diff --git a/drivers/clk/keystone/Kconfig b/drivers/clk/keystone/Kconfig index 7e9f0176578a6..b04927d06cd10 100644 --- a/drivers/clk/keystone/Kconfig +++ b/drivers/clk/keystone/Kconfig @@ -7,7 +7,7 @@ config COMMON_CLK_KEYSTONE config TI_SCI_CLK tristate "TI System Control Interface clock drivers" - depends on (ARCH_KEYSTONE || COMPILE_TEST) && OF + depends on (ARCH_KEYSTONE || ARCH_K3 || COMPILE_TEST) && OF depends on TI_SCI_PROTOCOL default ARCH_KEYSTONE ---help--- From patchwork Fri Nov 22 10:28:44 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 179993 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp36297ilf; Fri, 22 Nov 2019 02:53:04 -0800 (PST) X-Google-Smtp-Source: APXvYqwEuaYNxa16GlDBrgQEkQL5G3QND18zyw0gKbLgIjEf+6oS7rAGSW87qwD7nusIFWkC2tp/ X-Received: by 2002:aa7:d295:: with SMTP id w21mr257550edq.13.1574419984029; Fri, 22 Nov 2019 02:53:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574419984; cv=none; d=google.com; s=arc-20160816; b=qjq3HTqSQ3YK1qLCxpbqWOLM2T+uMCtE3h28VFxwvQNH2KF50RMXt8td/HZQf60OLs rM3u5cPBr8BylOw/0V09jBIwt61gg1Y3gVW1Pw5XPh0GcuJRcSsWUgmVMOl9qa1MtTPF 3qdQu5JPX0j20jGmca2sgIp4vXJ7qHOzfshhBaobWSSLGcERrkaR5fGfmvYbiZPkGvSj SovdTV1YPFy2+IOaVWSDegRR5Pd5qB2lgswqNjHLAhKgmeondcNlc83Dstr6Li6gEN9P Dfj6e0Nh3nncm43KV9660Oa/K0CCCPWN8tdIu/06tQp7UbY/rxCxM+o888l0O7xxQH6p V8pA== 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:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=r1+T/wUd+YTEVNZQdu+8J1D2JSpEqIhk1Fhv7pAvSwg=; b=NGpGH0q1FDFwEymvmI7DLnsCyYqdwfl77GQ5lCjMSUp5xEpC8aV72X+dZBmlYfKj69 gPusD2/Nhke1ABWrT9RT1PVU/eSmZ9HXQgKYWDjXN0JfNOuHdJEXP/9c5W7aHcs7e8ms ixmawO61aarYo/+jPp16elKcTHZZjgITWk4CFhoY/YIqVgNIBbn8FljPHRR83PxvpR4d yMfARkD+zvBj9SALUE953m69n+gpy8vTd6+Gcz9Cr/7ZLO55evTetz4U3SiDpdiqpgPz pKUjsamT6nTKm6++9OCnwzpcugCYWtfMbqHEpqztvqWRzEMYdj5U36+td3N8y3f6Bw9T hwxw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=nZWJpA5f; 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 dt11si3960742ejb.126.2019.11.22.02.53.03; Fri, 22 Nov 2019 02:53:04 -0800 (PST) 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=@kernel.org header.s=default header.b=nZWJpA5f; 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 S1729914AbfKVKxB (ORCPT + 26 others); Fri, 22 Nov 2019 05:53:01 -0500 Received: from mail.kernel.org ([198.145.29.99]:37056 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729818AbfKVKw6 (ORCPT ); Fri, 22 Nov 2019 05:52:58 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id ECFAD2070E; Fri, 22 Nov 2019 10:52:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574419977; bh=mBWSYqzntZrRXyv64akBAkmmXnttEMUiQhS1mPu6nLE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=nZWJpA5fLJg+GtToBs0HRMifwewvsnSGW5yDkykjB0fxx7XQ7vgAIOwPKCrlWu4zc 1v4GuG/puJqlzTvion3m+bfSmnPFnXF5vDVOszQKJwGnnfOzIdOiuBsQfvrtuoLqzc CVcYqRcvO+FLoV7KCuGstCW1jdI5vVxVFWlglZU8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Marek Szyprowski , Sylwester Nawrocki , Sasha Levin Subject: [PATCH 4.14 071/122] clk: samsung: Use clk_hw API for calling clk framework from clk notifiers Date: Fri, 22 Nov 2019 11:28:44 +0100 Message-Id: <20191122100812.169654382@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191122100722.177052205@linuxfoundation.org> References: <20191122100722.177052205@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Marek Szyprowski [ Upstream commit 1da220e3a5d22fccda0bc8542997abc1d1741268 ] clk_notifier_register() documentation states, that the provided notifier callbacks associated with the notifier must not re-enter into the clk framework by calling any top-level clk APIs. Fix this by replacing clk_get_rate() calls with clk_hw_get_rate(), which is safe in this context. Signed-off-by: Marek Szyprowski Signed-off-by: Sylwester Nawrocki Signed-off-by: Sasha Levin --- drivers/clk/samsung/clk-cpu.c | 6 +++--- drivers/clk/samsung/clk-cpu.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) -- 2.20.1 diff --git a/drivers/clk/samsung/clk-cpu.c b/drivers/clk/samsung/clk-cpu.c index 6686e8ba61f9f..82f023f29a61f 100644 --- a/drivers/clk/samsung/clk-cpu.c +++ b/drivers/clk/samsung/clk-cpu.c @@ -152,7 +152,7 @@ static int exynos_cpuclk_pre_rate_change(struct clk_notifier_data *ndata, struct exynos_cpuclk *cpuclk, void __iomem *base) { const struct exynos_cpuclk_cfg_data *cfg_data = cpuclk->cfg; - unsigned long alt_prate = clk_get_rate(cpuclk->alt_parent); + unsigned long alt_prate = clk_hw_get_rate(cpuclk->alt_parent); unsigned long alt_div = 0, alt_div_mask = DIV_MASK; unsigned long div0, div1 = 0, mux_reg; unsigned long flags; @@ -280,7 +280,7 @@ static int exynos5433_cpuclk_pre_rate_change(struct clk_notifier_data *ndata, struct exynos_cpuclk *cpuclk, void __iomem *base) { const struct exynos_cpuclk_cfg_data *cfg_data = cpuclk->cfg; - unsigned long alt_prate = clk_get_rate(cpuclk->alt_parent); + unsigned long alt_prate = clk_hw_get_rate(cpuclk->alt_parent); unsigned long alt_div = 0, alt_div_mask = DIV_MASK; unsigned long div0, div1 = 0, mux_reg; unsigned long flags; @@ -432,7 +432,7 @@ int __init exynos_register_cpu_clock(struct samsung_clk_provider *ctx, else cpuclk->clk_nb.notifier_call = exynos_cpuclk_notifier_cb; - cpuclk->alt_parent = __clk_lookup(alt_parent); + cpuclk->alt_parent = __clk_get_hw(__clk_lookup(alt_parent)); if (!cpuclk->alt_parent) { pr_err("%s: could not lookup alternate parent %s\n", __func__, alt_parent); diff --git a/drivers/clk/samsung/clk-cpu.h b/drivers/clk/samsung/clk-cpu.h index d4b6b517fe1b4..bd38c6aa38970 100644 --- a/drivers/clk/samsung/clk-cpu.h +++ b/drivers/clk/samsung/clk-cpu.h @@ -49,7 +49,7 @@ struct exynos_cpuclk_cfg_data { */ struct exynos_cpuclk { struct clk_hw hw; - struct clk *alt_parent; + struct clk_hw *alt_parent; void __iomem *ctrl_base; spinlock_t *lock; const struct exynos_cpuclk_cfg_data *cfg; From patchwork Fri Nov 22 10:28:51 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 180004 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp38363ilf; Fri, 22 Nov 2019 02:55:02 -0800 (PST) X-Google-Smtp-Source: APXvYqxOn0Q+rUrCu/KPMKZFtkOf/6R4sHLBCbWfCHdM//h9/zqVtXZor9PmUtHYCUOpzCdNxtDq X-Received: by 2002:a50:a691:: with SMTP id e17mr267592edc.151.1574420102000; Fri, 22 Nov 2019 02:55:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574420101; cv=none; d=google.com; s=arc-20160816; b=oA0QJrfURiBCLYsRNjKvNpB/gh4gqQDlCckJ1O2eF9b10Ze3g0IK7jVr3HtOFACMep Iz9/QYs6z2ZV4/CDU0+EcSwvM1mtLrrdayXBw6UDfrRup92PREsbwT27+Xqn4DqvwRlf dXdZlSJoxAIEQwPQqpI370oCrnVmg9uUAgnXdDyqlO3vnruHQ1onMnB7ijQ7UIe8pg4x wJtzJzn+UCaOLkgSLKfovzMzfdj1gbX3IPb0s4u8eg2S9X0xVGBFit/cRTcopz04IjW4 /EopJH0DylFEQDlpNw9aM+tvrRFKWa5YsRsS7mdmbEWtCqzyY5znvS31yOVFtwU0jd31 Ky+g== 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:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=HJ/Ap/Ol1QfVwHAO8Wnda4Cb2aGLIq3ld34sORxjTeQ=; b=RCsAzUoUkVlRn1kcKaTzjdcM5A1LxwcNabPdfn1DUDs5hWSrUm61DUEJwmTIRpQ3Gs APgEFeN0kf0giIG3Ko3oJe63jju3zreTuw2slhB8bc/LyuZjUJWY1z1VNTEwt8/b8NAz 6ggWXe4MmDcbYH8zX+Pe/BuhkqwDcuFmhOHjTepcR93Zfn21s+qTFV5kWsmCQB0IKQsF yOrcUmF0O/r6OK36qaX2HWvQX4ja7P0QW+sFBH/N3JrItWyeZPMTbSiZk4FLajs+rZuL lqd69BdfakUxkRUyDnmGmAtUv2yMc7f1hVQfocESawdBlVdZZBzTf6x1hlvJ0ZCXWFWW F1hg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=rANbdL93; 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 l15si1189843ejd.187.2019.11.22.02.55.01; Fri, 22 Nov 2019 02:55:01 -0800 (PST) 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=@kernel.org header.s=default header.b=rANbdL93; 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 S1728973AbfKVKzA (ORCPT + 26 others); Fri, 22 Nov 2019 05:55:00 -0500 Received: from mail.kernel.org ([198.145.29.99]:41158 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730394AbfKVKy6 (ORCPT ); Fri, 22 Nov 2019 05:54:58 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 20CE42071C; Fri, 22 Nov 2019 10:54:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574420097; bh=GTMVDaXzuzU2Vu00XLlOwXvvEsFSRCcG11kDpNM1lzw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=rANbdL93v19VceodQY3smlEwk7Yak1rfD4iJTo7+WYAgWTIc/uMv6r5kDnEThrZbO Ch9tKxgxbL3UOHJ6wjqDniwLQvxc40KOzIyrCuX5daq7UdLNEStWtog6t6ElBYyIkS F5pfKSmtiIegLCI5faTQTfhiFbI6s+afrqezmOz0= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Arnaud Pouliquen , Suman Anna , Bjorn Andersson , Sasha Levin Subject: [PATCH 4.14 078/122] remoteproc: Check for NULL firmwares in sysfs interface Date: Fri, 22 Nov 2019 11:28:51 +0100 Message-Id: <20191122100818.237329904@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191122100722.177052205@linuxfoundation.org> References: <20191122100722.177052205@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Suman Anna [ Upstream commit faeadbb64094757150a8c2a3175ca418dbdd472c ] The remoteproc framework provides a sysfs file 'firmware' for modifying the firmware image name from userspace. Add an additional check to ensure NULL firmwares are errored out right away, rather than getting a delayed error while requesting a firmware during the start of a remoteproc later on. Tested-by: Arnaud Pouliquen Signed-off-by: Suman Anna Signed-off-by: Bjorn Andersson Signed-off-by: Sasha Levin --- drivers/remoteproc/remoteproc_sysfs.c | 5 +++++ 1 file changed, 5 insertions(+) -- 2.20.1 diff --git a/drivers/remoteproc/remoteproc_sysfs.c b/drivers/remoteproc/remoteproc_sysfs.c index 47be411400e56..3a4c3d7cafca3 100644 --- a/drivers/remoteproc/remoteproc_sysfs.c +++ b/drivers/remoteproc/remoteproc_sysfs.c @@ -48,6 +48,11 @@ static ssize_t firmware_store(struct device *dev, } len = strcspn(buf, "\n"); + if (!len) { + dev_err(dev, "can't provide a NULL firmware\n"); + err = -EINVAL; + goto out; + } p = kstrndup(buf, len, GFP_KERNEL); if (!p) { From patchwork Fri Nov 22 10:29:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 180019 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp63439ilf; Fri, 22 Nov 2019 03:13:56 -0800 (PST) X-Google-Smtp-Source: APXvYqzSe6kZwYR3mj81CmNa1hSCMRjrNRWiVLCSQrJVIIa9x/yzB/JEVAp9eV9V0nUMeXiiIebb X-Received: by 2002:a17:906:c2d6:: with SMTP id ch22mr21944722ejb.262.1574421236678; Fri, 22 Nov 2019 03:13:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574421236; cv=none; d=google.com; s=arc-20160816; b=B46zil0OWG7VTi6AorRyLl7wbOQ/KkZPf73o8Aj4vm4xYoox/HILzd3riMXx16IRFg t1Mo8fgN42YpbOq2jvVQwQQiOJBzumaxIoIAiLghKz9mRD3YaG2iGu32ActcWsB8J0Xh h4NyLzGHWyjX6gZu772vbjJwXIzxDZ64qaBG00F6P+X6qIKFPXFvyOi2UJHSfgBkYLW6 b3HAihjz30ng0Zt58xJ3f1zczD2sfiUdXPpDs3j0apKLWsjNS8zDZzLWfmpE47YhneA/ nCdA1id3xHWQTEPTXAVoIOjg+ixyVobvkFWpoErt5/y5prBY/F4Ik5TMJdtqTs90l5yA nF1Q== 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:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=vDVArhvsaUjEmbhWfAlsh77EdfA/jkKziAziNW+k+h4=; b=wrKZEVqPcMwMUGe8BQWTwe3KENL7plu2JrLT9nRacQwKet7fcwz+qfUJi/HdlyWeJG II6HaTUypry+hWUA8KLchQO8KLLf+ZLgI6fr3liBHaUQ2+XPn9AAVs2JRG5dR4uhOQDq Vfk0ZnwxAW8kSiHqsG8trR7xkHt562pqUpBQwg9lqF2YOBg3dWVQx3rqZKNgpcIEBmn/ HqNBO6aSHf6vAOiSs8gcZ7uNtwVxWfvzwpGIgcEhGoqkWfCkmWUyW962433t55qIlObR /xeM+p7GCSIdQsSeOxfq0BQV+5eugvFpYpgnpw9v9SojDDq1YKoyUQXRBX0uNpMezulh 3c7Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=vPj6wGbV; 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 ch17si4055882ejb.184.2019.11.22.03.13.56; Fri, 22 Nov 2019 03:13:56 -0800 (PST) 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=@kernel.org header.s=default header.b=vPj6wGbV; 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 S1730346AbfKVKyg (ORCPT + 26 others); Fri, 22 Nov 2019 05:54:36 -0500 Received: from mail.kernel.org ([198.145.29.99]:40196 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727991AbfKVKyd (ORCPT ); Fri, 22 Nov 2019 05:54:33 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 10EF620706; Fri, 22 Nov 2019 10:54:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574420071; bh=5ZZg/xigrTA2+oyrMBGTOMx97kcHllNc7EFKeSaV/nQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=vPj6wGbVT9wKmO/kQ45Ay0l1k4eSSw+5RrXporQnB4c2QNg6jtXsK6X8n16aZjno3 eW8HwPrIllHm2EAWRVIecz48I0OBdO1rYbSE0ZuMF1E6zL2XM8ZQpMW3X6+8aOx4yX taOGaCR8aGFFba23jyyC2M3c/5ax/C41Zw5MJwUg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Linus Walleij , Sasha Levin Subject: [PATCH 4.14 105/122] pinctrl: gemini: Mask and set properly Date: Fri, 22 Nov 2019 11:29:18 +0100 Message-Id: <20191122100832.406597374@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191122100722.177052205@linuxfoundation.org> References: <20191122100722.177052205@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Linus Walleij [ Upstream commit d17f477c5bc6b4a5dd9f51ae263870da132a8e89 ] The code was written under the assumption that the regmap_update_bits() would mask the bits in the mask and set the bits in the value. It missed the points that it will not set bits in the value unless these are also masked in the mask. Set value bits that are not in the mask will simply be ignored. Fixes: 06351d133dea ("pinctrl: add a Gemini SoC pin controller") Signed-off-by: Linus Walleij Signed-off-by: Sasha Levin --- drivers/pinctrl/pinctrl-gemini.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- 2.20.1 diff --git a/drivers/pinctrl/pinctrl-gemini.c b/drivers/pinctrl/pinctrl-gemini.c index 39e6221e71000..05441dc2519d2 100644 --- a/drivers/pinctrl/pinctrl-gemini.c +++ b/drivers/pinctrl/pinctrl-gemini.c @@ -2164,7 +2164,8 @@ static int gemini_pmx_set_mux(struct pinctrl_dev *pctldev, func->name, grp->name); regmap_read(pmx->map, GLOBAL_MISC_CTRL, &before); - regmap_update_bits(pmx->map, GLOBAL_MISC_CTRL, grp->mask, + regmap_update_bits(pmx->map, GLOBAL_MISC_CTRL, + grp->mask | grp->value, grp->value); regmap_read(pmx->map, GLOBAL_MISC_CTRL, &after); From patchwork Fri Nov 22 10:29:20 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 180002 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp38000ilf; Fri, 22 Nov 2019 02:54:43 -0800 (PST) X-Google-Smtp-Source: APXvYqyqZ3L7ltWWcCzjM0bcpmQ2FAE8e0zHCeMkO/nkUSp+ncyCZQttIt5RZIYLT/DguuO6QBKo X-Received: by 2002:a17:906:7fcb:: with SMTP id r11mr21297184ejs.85.1574420083009; Fri, 22 Nov 2019 02:54:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574420083; cv=none; d=google.com; s=arc-20160816; b=N+KvmlhSubwqcOOVw1QeVnPuCLcCS0uzMnlORLyQYZKEEHDXyJWTvclJ9n9l8AXUgv HickXQ5sibCa8KBMg1ias5luDMQ8lUfG8Z5u3Vk0tlpPqoe4oj8IkA9fCFJ686IaNBT8 Vjt3BnLc6cSe31sZR40RDI38Ou3fpiCdyLilIOsfPqlOkIlZlZ5jJUFtghH+pWs2diqx LSOqh/7C7dZQ0o/JWckhFd9EqrKYhyXneegcPs2aAzV1ydWo1IfRr28Y8+qCouuFJiy3 RnEWhoLu3L3kjyH5vqk7wVe5WNDsRK2IruoWGVMRBWw6x+CNt53TmjfT9H7ZvFXDAJVN hZfA== 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:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=goR4uduhCydGBI1cFIPAMqKpMAMBC4644PHkunnOUcE=; b=Ftnd4qbLWfamXReOHiSFUS8DuzpX6FdNBNNjii3QfhF/gRt9bCu+H4kthqXm+Wq0NZ 4hwk0ZOYgrG1eRPYH3MMvspYpQL8S+AXfGUB8dFhFQJQ33Snby4LYkKYjNYR+Q946b53 nWLpUWyIyWCoM0CYn9xhJO1t9/DcA0tSxHYq8enIyWTmE5bybQkr7/5dN5LPOkNtae2M 0u3ROFVWgXo5+QwY1YJGdg/0xKQ1j+wweXJDzZ+O62gJaoRAd3I0mMBXhqvqKte7z3l7 vcVveRFyQ8IzGVRoJa8rMUiRz5H35eDoLgb7iyb/9EtoiXX3EVqo3sqHm6laj4ady+NX IF+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=x3+BwOdx; 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 q30si4876722edb.372.2019.11.22.02.54.42; Fri, 22 Nov 2019 02:54:42 -0800 (PST) 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=@kernel.org header.s=default header.b=x3+BwOdx; 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 S1730360AbfKVKyk (ORCPT + 26 others); Fri, 22 Nov 2019 05:54:40 -0500 Received: from mail.kernel.org ([198.145.29.99]:40414 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730351AbfKVKyh (ORCPT ); Fri, 22 Nov 2019 05:54:37 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id EF87C2072E; Fri, 22 Nov 2019 10:54:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574420077; bh=FQxdcPlHeuxk12YE2UCy2y47gJFvSt793ga4V9vyrog=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=x3+BwOdxuGyUysXRzVx33hVmo7SS3uTx6WnbZT+saHih6IJWkoVOvKLWZDmSFWTwu xDWDp2pakjy4ymzd58Bnke7byunbt5l+Q8Ysw3SHoKMmdjuTUJgwv230QKq2KPovzF +3fzUY+q2tZTINCm1sNCggdlp8m8hW8j2RdEHKM8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Timothy E Baldwin , Eugene Syromyatnikov , Kees Cook , Russell King , Sasha Levin Subject: [PATCH 4.14 107/122] ARM: 8802/1: Call syscall_trace_exit even when system call skipped Date: Fri, 22 Nov 2019 11:29:20 +0100 Message-Id: <20191122100833.086512348@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191122100722.177052205@linuxfoundation.org> References: <20191122100722.177052205@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Timothy E Baldwin [ Upstream commit f18aef742c8fbd68e280dff0a63ba0ca6ee8ad85 ] On at least x86 and ARM64, and as documented in the ptrace man page a skipped system call will still cause a syscall exit ptrace stop. Previous to this commit 32-bit ARM did not, resulting in strace being confused when seccomp skips system calls. This change also impacts programs that use ptrace to skip system calls. Fixes: ad75b51459ae ("ARM: 7579/1: arch/allow a scno of -1 to not cause a SIGILL") Signed-off-by: Timothy E Baldwin Signed-off-by: Eugene Syromyatnikov Reviewed-by: Kees Cook Tested-by: Kees Cook Tested-by: Eugene Syromyatnikov Signed-off-by: Russell King Signed-off-by: Sasha Levin --- arch/arm/kernel/entry-common.S | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) -- 2.20.1 diff --git a/arch/arm/kernel/entry-common.S b/arch/arm/kernel/entry-common.S index d7dc808a3d154..08a7132f56006 100644 --- a/arch/arm/kernel/entry-common.S +++ b/arch/arm/kernel/entry-common.S @@ -282,16 +282,15 @@ __sys_trace: cmp scno, #-1 @ skip the syscall? bne 2b add sp, sp, #S_OFF @ restore stack - b ret_slow_syscall -__sys_trace_return: - str r0, [sp, #S_R0 + S_OFF]! @ save returned r0 +__sys_trace_return_nosave: + enable_irq_notrace mov r0, sp bl syscall_trace_exit b ret_slow_syscall -__sys_trace_return_nosave: - enable_irq_notrace +__sys_trace_return: + str r0, [sp, #S_R0 + S_OFF]! @ save returned r0 mov r0, sp bl syscall_trace_exit b ret_slow_syscall From patchwork Fri Nov 22 10:29:32 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 180005 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp38722ilf; Fri, 22 Nov 2019 02:55:22 -0800 (PST) X-Google-Smtp-Source: APXvYqwVe4aDlodrJkNwYMUec+nB/8YHespvMAWq7HHuSyWVGS/uTSLENfE+vnn5Y/VTjZZp7Uec X-Received: by 2002:a17:906:6552:: with SMTP id u18mr21296445ejn.36.1574420121919; Fri, 22 Nov 2019 02:55:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574420121; cv=none; d=google.com; s=arc-20160816; b=gNCdtKNht98iug5w8g71OK4HhyqC7Jg4cXiV3XAyV+O/vWgyyDuSolIxRXiseteAib Ta/GVT4AJ5dZiwrxlv4mvf73PXcDEIJgl5to0tPzO/zNjEUAbjJOSsuQURiCfB0cRybY nbrwkT2FQHZvXHpnCLt3R7CT9FQ8uzqamn9TKkaTRctVyK6mayPU7MxDfllNh/f9Eagr B2xnsHgLPHUGp7hIDNTxmg4Jawm4AA0/XVTVURmxXxOoj/UMT2/YC79Cr9eFEsDtjuTW WVrP5499i2YcoDkunNCX3naKiYvyGYgjqnIg+iu7ZbXzWsx9kkAhXw+R9AhqGmJrjH6i OxYQ== 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:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=xpTX/pP0aD3bIeTIJWQeOKdhjvypqmKHcS3RPRMcEYo=; b=ZBM/7+iv/wSNnI8rEbWsEiQi3qO6KGz403OcVz5YYnnhc9qaahT+XZF5L190A/CRbg aXzMzZfhVR/EuhI2CxMWuwsXVCNqosxCNAjDtoXQycpalGzmdRQ/23SQWmcy+7/9OQ1E dsm8xa9Udt5xFvUNpu0PrDkUXuG47pQrmJmNxQnvxPVEHmsXRKXu8gaBIdK40TkU3eN/ RDaR+zTdJJG6A6iu7aHGq//LxhX9BGPlxB/E3jf7kVYr+rVwf6X1S7DpLGs6AZ79Er0g xCV+sDPpzWA/27esHEKnAl0OFU5feOMfp7eZoiKHfCk3m4dtEWj9Z+9d0iQsCEgB4KNf kSFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=OWtVenTn; 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 w47si4529234edd.326.2019.11.22.02.55.21; Fri, 22 Nov 2019 02:55:21 -0800 (PST) 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=@kernel.org header.s=default header.b=OWtVenTn; 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 S1730452AbfKVKzT (ORCPT + 26 others); Fri, 22 Nov 2019 05:55:19 -0500 Received: from mail.kernel.org ([198.145.29.99]:41824 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730439AbfKVKzP (ORCPT ); Fri, 22 Nov 2019 05:55:15 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E114020706; Fri, 22 Nov 2019 10:55:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574420115; bh=E4c7E0E0gF6jfSVz2Pxox2hy9Q5loNqXt/ABscsuXqo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=OWtVenTnxN3Vw6UN2Un07beD1ZckxjXWCwdmc6xPDdfV2BIXbE8121f3bYQZDDuEv SBiORRQPmyauANLqvqgU0C8U3kuR+nm3CZpg9EFnJmD2lRzoIb5NJzXdXhgL/CYyeE Lllwr7BZTXMH/JJHrCAWIpH3S6v9De6FCJDmpNX4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, "H. Nikolaus Schaller" , Roger Quadros , Tony Lindgren , Sasha Levin Subject: [PATCH 4.14 119/122] ARM: dts: omap5: Fix dual-role mode on Super-Speed port Date: Fri, 22 Nov 2019 11:29:32 +0100 Message-Id: <20191122100837.456100988@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191122100722.177052205@linuxfoundation.org> References: <20191122100722.177052205@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Roger Quadros [ Upstream commit a763ecc15d0e37c3a15ff6825183061209832685 ] OMAP5's Super-Speed USB port has a software mailbox register that needs to be fed with VBUS and ID events from an external VBUS/ID comparator. Without this, Host role will not work correctly. Fixes: 656c1a65ab55 ("ARM: dts: omap5: enable OTG role for DWC3 controller") Reported-by: H. Nikolaus Schaller Signed-off-by: Roger Quadros Signed-off-by: Tony Lindgren Signed-off-by: Sasha Levin --- arch/arm/boot/dts/omap5-board-common.dtsi | 1 + 1 file changed, 1 insertion(+) -- 2.20.1 diff --git a/arch/arm/boot/dts/omap5-board-common.dtsi b/arch/arm/boot/dts/omap5-board-common.dtsi index f65343f8e1d69..c58f14de01451 100644 --- a/arch/arm/boot/dts/omap5-board-common.dtsi +++ b/arch/arm/boot/dts/omap5-board-common.dtsi @@ -695,6 +695,7 @@ }; &dwc3 { + extcon = <&extcon_usb3>; dr_mode = "otg"; };