Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1372858pxu; Sat, 5 Dec 2020 13:45:28 -0800 (PST) X-Google-Smtp-Source: ABdhPJwCM3wjSTG2VWVR9hBVlB/FA71S6jahqyaPV1kb/xOYG5IihIe2E0aDKzDTsuNKTxdHX8xv X-Received: by 2002:a05:6402:19b4:: with SMTP id o20mr13626114edz.103.1607204727939; Sat, 05 Dec 2020 13:45:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607204727; cv=none; d=google.com; s=arc-20160816; b=juYmpMFSu3ez8sYfPrYrU/ZhLwgbtA4OfNzViy1wYLirxluDADG0oT3ZNgCUswb6YN VC1Noj7ufopvIUN0vvAqt6fpvcKLzkWo6jZlo1wczoaAmFO89sMKAHJ94ri/rTNKz6Rh qSInIs1zn7BACmjqV03dMXfkzG53ZTkAHo4q3N9kYEXI3OmIMksM8dOCUmXWcLcUjIut uCsZL1woXb+fh++RpUdLOfLzIWvI234oXOwOIGhxtHVDQEzsOeDX7p7n1ZnB4Q6P4EmU xK3Mds1rbfE1iv+1pGdrKiqFrWh2gQHB6keFwONjZ/89VwCgqaG+9Pm1xlxDuv02DTtn PaQQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=BcFwvccBZsNRXg6tthMMYxCZiveruOlpyGXOybgngvQ=; b=j9yM23czYpAwQhYIyJpJoNttBATHZhvZN4Nxq1ZjpwQN4fTslwfQW4d2P6QvoOpA9Y 9J6QZ9VrQloM4R/gVbU8QoicWrqU9OS5d18T+La6cKYjbHUbcojIO1Yshk/wAdJ+dRbC Y8NU+fenI0v7aoPmV//A64KXUD1JShDbF8kEC2/rVy+rrgTNKG4d2hLOXYue04W1ejPk WunCSXNq4MN1/wcv262r9VjloRI/Cd70afI4SFvOkW6OZwAaezHA0Iqfhk4P0jtnf4Cr EWHsrqc8TWbWmeyRpXwstBjMTb8VaaDq3XwX11xMHRMxT4lIJmRHXka04ZjGnyoSzm52 rvbA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@googlemail.com header.s=20161025 header.b=jiOiKlaZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q23si3999887eja.104.2020.12.05.13.45.03; Sat, 05 Dec 2020 13:45:27 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@googlemail.com header.s=20161025 header.b=jiOiKlaZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726820AbgLEVnY (ORCPT + 99 others); Sat, 5 Dec 2020 16:43:24 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43622 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725601AbgLEVnX (ORCPT ); Sat, 5 Dec 2020 16:43:23 -0500 Received: from mail-ej1-x643.google.com (mail-ej1-x643.google.com [IPv6:2a00:1450:4864:20::643]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CEC91C0613D1; Sat, 5 Dec 2020 13:42:42 -0800 (PST) Received: by mail-ej1-x643.google.com with SMTP id m19so13879826ejj.11; Sat, 05 Dec 2020 13:42:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=BcFwvccBZsNRXg6tthMMYxCZiveruOlpyGXOybgngvQ=; b=jiOiKlaZJLpwxmeKjTWxcVGZCEkUHCWFjES5nFUbk1CJYTGVEBHGjg29kLi2I3rTP4 m9uZo8fJZqILlx2qptuTXKjm8L3+xYj0ur8Il1W4lB787lPdbAJBSoBcbQDDNpwq8utp B9n8Qaa0mIJMAnY9riPCBaVcPSeTQc6u7VB8OWzVTPBk4QT9ecKg857smbCm4YoTwDJ1 UkHuSfQPCQ1y4sKVFAnCgb9Ms/9dFyvn1N57jUS/WTHmsLxa6JCRlLCvd7YlKffUIsXl xPNVSYDHhQKZQJDOkaMPjS7RteEZNrFy7lY63xLz9S7MaWT8F9cXKDpLPWTQD5+SIa54 FdDg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=BcFwvccBZsNRXg6tthMMYxCZiveruOlpyGXOybgngvQ=; b=djEJQuhbewQm5RAT58W317kLG/mcuZ6nc8s6jBipWemUIBqWBLsu+LHzbeIAw7ICJ+ I/uUt/FYBCcMsAJTR1zfoNsyj9DWExMe/yWGdV0wuCAIow0hjoVdOC56r8GOindL/kWG CCvq6kWLROVA5ZDbyskG/NXiaQzm61ClhHqtu+xhi94BHaNiP6WwZY5/Pc5K1+IfprON Ml5MOyKlU/vOtLKeX/9hQnLAPK2dD33ExHMfiALOM+ddsgcqVo0NEjGsm05/3sSQxW9m JTmAF0Tc0KFt4brxZO0gTdkDTxm2tHwx0bOg/X3iVZthS3x1ZtyCzQViZ5ce8KD6Arsz vMtA== X-Gm-Message-State: AOAM531yKfQXbmBu5CVJb6OkorPlnyNrStHBatAf4gcrMn0sz2nYJs7E fppzhPAW7jIdVRhP/zBf+55gnWwW9kjD3K2t1Bw= X-Received: by 2002:a17:906:447:: with SMTP id e7mr5694784eja.172.1607204561424; Sat, 05 Dec 2020 13:42:41 -0800 (PST) MIME-Version: 1.0 References: <20201201190100.17831-1-aouledameur@baylibre.com> <20201201190100.17831-3-aouledameur@baylibre.com> In-Reply-To: <20201201190100.17831-3-aouledameur@baylibre.com> From: Martin Blumenstingl Date: Sat, 5 Dec 2020 22:42:30 +0100 Message-ID: Subject: Re: [PATCH v2 2/3] usb: dwc3: meson-g12a: fix shared reset control use To: Amjad Ouled-Ameur Cc: Felipe Balbi , Kevin Hilman , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, Philipp Zabel , linux-amlogic@lists.infradead.org, Jerome Brunet Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello Amjad, On Tue, Dec 1, 2020 at 8:01 PM Amjad Ouled-Ameur wrote: > > reset_control_(de)assert() calls are called on a shared reset line when > reset_control_reset has been used. This is not allowed by the reset > framework. > > Use reset_control_rearm() call in suspend() and remove() as a way to state > that the resource is no longer used, hence the shared reset line > may be triggered again by other devices. Use reset_control_rearm() also in > case probe fails after reset() has been called. > > reset_control_rearm() keeps use of triggered_count sane in the reset > framework, use of reset_control_reset() on shared reset line should be > balanced with reset_control_rearm(). I think this should be updated after [0] is applied The goto from that patch needs to use err_rearm from this patch. Best regards, Martin [0] https://patchwork.kernel.org/project/linux-usb/patch/20201111095256.10477-1-zhengzengkai@huawei.com/