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 1C36B606A320 for ; Mon, 30 Nov 2026 22:55:10 +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=ZQ4Z4GZe; dkim=fail reason="signature verification failed" (2048-bit key) header.d=google.com header.i=@google.com header.a=rsa-sha256 header.s=20260707 header.b=EMIi+4ci DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:From:Subject:Message-ID: References:Mime-Version:In-Reply-To:Date:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Unsubscribe-Post:List-Owner; bh=kUC4cWbMDawkoPZBog2hBdE4qCjFrFee0ZmZ3WrjnrM=; b=ZQ4Z4GZe1ewnpJrloLxXdGo5Ky wWYaeJh0GoA3TmYfFWD/4GnOFw7JMkZt6ZN4voWH8K/nJKMhwzzfshaz/79odnyLO2Qw2Qiw3Nb0+ G1T9vCOhomNCZwsmAF2SLSnBlE9tuNfg+PzHOPJWYoeyVj2hPpGR4ivl9kYwlLQgYA0nUvt1UQplf JosckWrNAtZ8EZg/fySbAhBvMGAgeMjPOR+ls/GA1Ys5RP0s7GIKsXqr3ieTwDwp3F8QB3tXrxEZc bwO6b5NXR5pneqvSgHKrHIcivRzOnxmGMpn7uga8eAbmA7e8VcPLC3PjGh5Rtq1GMaDYlH3fKQ1jQ w03kPlEw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.100.1 #2 (Red Hat Linux)) id 1xYAH7-000000060z3-3CPr; Mon, 30 Nov 2026 22:55:09 +0000 Received: from mail-oo1-xc46.google.com ([2607:f8b0:4864:20::c46]) by bombadil.infradead.org with esmtps (Exim 4.100.1 #2 (Red Hat Linux)) id 1xYAGq-000000060pp-2gFA for linux-phy@lists.infradead.org; Mon, 30 Nov 2026 22:54:57 +0000 Received: by mail-oo1-xc46.google.com with SMTP id 006d021491bc7-71ade13044aso11065006eaf.0 for ; Mon, 30 Nov 2026 14:54:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20260707; t=1796079289; x=1796684089; 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=sG051382ioT5HtlTMptSOVf8d1qOSEco0Hvbb/hVCAE=; b=EMIi+4ciVIYAi6fsN4j7qrwzI62LvH5uSgSoEKWBksITDex/qoCvU5hOygfJo3gLG6 cy2NYuW2ucP9hdtGNqZGdgkv5gSKJ3xM+vcnnIqvMBaMVBe6aWtzo9BwN6BhB5ZYKu1B MUo2Cz4uhy2nHfYf8kkWxhcG9QUBKriBTXdnC/L6NEdLjrXbVvdyivmAdy3ulpzExqLu ef3VXgL72rLs4+LKjzVD01cwiWeGorgTH1w9BpfbM7V7siRXulp6ZTdg1RNHGPzrh+mn 01V3rRmr0E789nT50hB4wj9bU349MEYiWoSYpQPDvjp8E1bPpeJSSM2Kh2K9YpNcTNC1 vjVA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796079289; x=1796684089; 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=sG051382ioT5HtlTMptSOVf8d1qOSEco0Hvbb/hVCAE=; b=xtk57b3ukpLZonRJf/55WEUmICGaE23xVPecL45PLsRTDwylxhHFfV4CWt7T25vSiU 66mL5cS2I+oiVhbwMuC7GQfzLbTstyM4KYsq02tSRUvVKRKMSn801qYeNkSgleGaCIsH xphiAlnWc9lFiBCR+FmboOS03yh8Ky2jNhkj89ZFEM7YvS/2E5SeQ5AFnrH8H7NjHLID 46w9+lYCI8X5Y51fSYCuO10A7evmLyiwkOfIqMNcMT4jIV5LJ0hy/Tqo2wjJ4UeMumTp RoEwUKnXWFEde1lEnyHRfjysB5RirRZZJd5hKZB+hGyuBbdV/gCbgGDS3lG+ETHKF8E+ 6+BQ== X-Forwarded-Encrypted: i=1; AL+hErG/QDudAvQrfcZroKcv6780pF+8FitAFbbgUb5a92y/09GZyvPlsAOzTx3PKvmq6RPpQZiX9aR7wpI=@lists.infradead.org X-Gm-Message-State: APuU4Z8A8nt2LnP6ODgUEwG7+cBBIHVNOwl8s3unT+333nG2hjGEq8sB 4/tA02DIE4BTDh4FrndQ8X29rW+I4rpuKY4KSfLse8AgMsu/DiRegNEvJxvx9P/TCsn6q48N0h7 a16VSlGQJMA== X-Received: from oarb10-n2.prod.google.com ([2002:a05:6870:c04a:20b0:495:bb4d:1619]) (user=irogers job=prod-delivery.src-stubby-dispatcher) by 2002:a05:6820:4088:b0:708:f388:af75 with SMTP id 006d021491bc7-71b39576de0mr25807647eaf.46.1796079289357; Mon, 30 Nov 2026 14:54:49 -0800 (PST) Date: Mon, 30 Nov 2026 14:54:24 -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-9-irogers@google.com> Subject: [PATCH 08/10] phy: starfive: jh7110-dphy-rx: 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 , Jack Zhu , Changhuang Liang , Minda Chen X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20261130_145452_758274_89738ED6 X-CRM114-Status: UNSURE ( 8.90 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -9.5 (---------) X-BeenThere: linux-phy@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux Phy Mailing list List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-phy" X-Spam-Status: No, score=-16.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT 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 stf_dphy_ops, found with Clang's require_explicit_initialization attribute. Fixes: f8aa660841bc ("phy: starfive: Add mipi dphy rx support") Signed-off-by: Ian Rogers --- drivers/phy/starfive/phy-jh7110-dphy-rx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/phy/starfive/phy-jh7110-dphy-rx.c b/drivers/phy/starfive/phy-jh7110-dphy-rx.c index 043a7e11d187..895a9ff5ca0d 100644 --- a/drivers/phy/starfive/phy-jh7110-dphy-rx.c +++ b/drivers/phy/starfive/phy-jh7110-dphy-rx.c @@ -144,6 +144,7 @@ static const struct phy_ops stf_dphy_ops = { .configure = stf_dphy_configure, .power_on = stf_dphy_power_on, .power_off = stf_dphy_power_off, + .owner = THIS_MODULE, }; static int stf_dphy_probe(struct platform_device *pdev) -- 2.56.1.839.g22a8290db9-goog -- linux-phy mailing list linux-phy@lists.infradead.org https://lists.infradead.org/mailman/listinfo/linux-phy