From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6E2E9606A6AC for ; Mon, 30 Nov 2026 22:54:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=P2C+dE6S; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.a=rsa-sha256 header.s=20260707 header.b=lRxmQ8NW DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:Cc:To:From: Subject:Message-ID:References:Mime-Version:In-Reply-To:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Unsubscribe-Post:List-Owner; bh=cmHlKAUkq1WYBYUGRIowpJhABA5ObAwW952ix0epN/E=; b=P2C+dE6S8kCOGqijNA9SchyEVt 10P7xJWg6HclxOkl5tEnRot33VF3QwI3KPtSuKjO84YUda/fHRyyWRnzDPnnkQ+icfJkiKDHNUv2o 6Ht7I6r5gJleaz341dsLkuNmnkHZ3d0nOcSfWtvb17ybBxtT++I3IJtMusxsybx8jCVuG9TmUZ4hu zzyDpqO7rECPiuO8TmvMBQ56RKw9FrTjWDBmkXVOCcolVzy+GV8TFwiPlGKJ8jX40KSvB73T0st3k D6wpv7TwxHTrzgxpb0a03Yt9sJ0lVwBp8yxSvNVrper3k3oMkjmNt9BkzifExUEEwAk76NA9qvq/X Z6LyKtaA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.100.1 #2 (Red Hat Linux)) id 1xYAGh-000000060jf-37Rn; Mon, 30 Nov 2026 22:54:43 +0000 Received: from mail-dy1-x1348.google.com ([2607:f8b0:4864:20::1348]) by bombadil.infradead.org with esmtps (Exim 4.100.1 #2 (Red Hat Linux)) id 1xYAGa-000000060d2-3hcW for linux-arm-kernel@lists.infradead.org; Mon, 30 Nov 2026 22:54:38 +0000 Received: by mail-dy1-x1348.google.com with SMTP id 5a478bee46e88-341eff9e381so16087871eec.1 for ; Mon, 30 Nov 2026 14:54:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20260707; t=1796079274; x=1796684074; darn=lists.infradead.org; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:from:to:cc:subject:date:message-id:reply-to :content-type; bh=cmHlKAUkq1WYBYUGRIowpJhABA5ObAwW952ix0epN/E=; b=lRxmQ8NWf0KKrVDyF1moHHlQ0dwAZD0BiixntRNeXYi4bl7JcJU1//O5b4dciDMyyd OmcSzUOQqvtaVCcFVoSZB7F+dsP8LZP1qucpOVZ1POd4i6ejGZ+2ExDjuSeGtrN+IpLf t0WEfggu/jF/I76FwOFkdV+Jc6EdpVyRRCinmSShlFnRmnbnUfbCsRDp+RXgtmz+Vsu6 d1ofHukjtmusVahnnK8PU2LTQvabzGIbrchSqmyShEQTTzPn7/FkAQL045kTT7ahH4AO ktYwYwhXA3N1QXM+QePDHqagC+ahUPi4Ef/QFJ/g4MojN62Q5j5MXWs4AHaowGIjwaH/ zV+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796079274; x=1796684074; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=cmHlKAUkq1WYBYUGRIowpJhABA5ObAwW952ix0epN/E=; b=Otrd0Y2lfkpakiHe/ISu1OB1tBnZjt0HALx7jsQZurbPt0GLAP9wo306DhUH3ZwjJX 8/BRpqcC64PRleX0y1f4JwWIzSq6qASR4P6dFfFDs6PKycYWoYrgtCqa/5g5OoQ3w9Ua nO5mEESagoDIh4bDpo8OFFSViQeIsPT6tYlU3IWz5i3WWidQsG1nvVl/HQaE3umMVXHR hQtWfsmAOL/iS6ASaMks3IWgbuwrUtGTXO5UpCtCp7So3/DT+TxWidCZ6P3tzBndw6RX 3zl5rdoox1tFz319ZRT6rQShstDk/0kPGz9WyeKOS7e5c7mglwjNZnUepVEewVrI6NUC I0Xg== X-Forwarded-Encrypted: i=1; AL+hErF58qcsGZjxtsHFjqcSttVrzzVhus+No+CpgYZie9VZkhOedX4qaSlHmfzbkYNeE0CktnrWjLERpjoyD6LsMe/+@lists.infradead.org X-Gm-Message-State: APuU4Z+9dM+b/Q7zY7Q2dPhqy7d/PoAxdRi3LV4tjp1qV58M6EfIUFVt wYMqI2XQ4y/qPnWffz2wUWMY9sF/t+uEVDXC7InLRzXuPhzw4ysPVwabhHYcrMF/DyemnUxsdCS josOQd/7kEQ== X-Received: from dybsl8.prod.google.com ([2002:a05:7301:7308:b0:379:1aaf:7a27]) (user=irogers job=prod-delivery.src-stubby-dispatcher) by 2002:a05:693c:65cb:b0:386:b12f:c693 with SMTP id 5a478bee46e88-386b12fcaabmr22455176eec.39.1796079273373; Mon, 30 Nov 2026 14:54:33 -0800 (PST) Date: Mon, 30 Nov 2026 14:54:17 -0800 In-Reply-To: <20261130225428.99361-1-irogers@google.com> X-Archived-By: Mime-Version: 1.0 References: <20261130225428.99361-1-irogers@google.com> X-Mailer: git-send-email 2.56.1.839.g22a8290db9-goog Message-ID: <20261130225428.99361-2-irogers@google.com> Subject: [PATCH 01/10] phy: allwinner: phy-sun6i-mipi-dphy: Set .owner = THIS_MODULE From: Ian Rogers To: Vinod Koul Cc: Neil Armstrong , Manivannan Sadhasivam , Nathan Chancellor , linux-phy@lists.infradead.org, llvm@lists.linux.dev, linux-kernel@vger.kernel.org, Ian Rogers , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Maxime Ripard , Paul Kocialkowski , linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev Content-Type: text/plain; charset="UTF-8" X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20261130_145437_218876_09A5C9E0 X-CRM114-Status: GOOD ( 10.07 ) X-Spam-Score: -9.5 (---------) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" X-Spam-Status: No, score=-26.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIMWL_WL_MED,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT, USER_IN_DEF_DKIM_WL autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 phy_get() and of_phy_get() call try_module_get(phy->ops->owner) to pin the PHY provider module while the PHY is in use, and of_phy_put() calls module_put(phy->ops->owner). Because phy->ops is const struct phy_ops *, phy_create() cannot populate ops->owner at runtime, and try_module_get(NULL) returns true without incrementing the module reference count. Set .owner = THIS_MODULE in sun6i_dphy_ops, found with Clang's require_explicit_initialization attribute. Fixes: bb3b6fcb6849 ("sun6i: dsi: Convert to generic phy handling") Signed-off-by: Ian Rogers --- drivers/phy/allwinner/phy-sun6i-mipi-dphy.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/phy/allwinner/phy-sun6i-mipi-dphy.c b/drivers/phy/allwinner/phy-sun6i-mipi-dphy.c index e5a9aa3f4aac..663b3d4d295b 100644 --- a/drivers/phy/allwinner/phy-sun6i-mipi-dphy.c +++ b/drivers/phy/allwinner/phy-sun6i-mipi-dphy.c @@ -535,6 +535,7 @@ static const struct phy_ops sun6i_dphy_ops = { .power_off = sun6i_dphy_power_off, .init = sun6i_dphy_init, .exit = sun6i_dphy_exit, + .owner = THIS_MODULE, }; static const struct regmap_config sun6i_dphy_regmap_config = { -- 2.56.1.839.g22a8290db9-goog