From nobody Sun Feb 8 02:56:20 2026 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DB7EC35EDCD for ; Wed, 14 Jan 2026 08:09:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768378165; cv=none; b=M2InLZncz0v5ettCv1nBFGKSFtIqZxI24osPgvCa04oBy2ZQwJ0yGlaRxZQXpijZ8h9bRsvZunn0Wl4boFVRFmmp/L0pYBL3KXnxjqA554u6MFUQkWJDhFVWsZEBCjMzuWjdqV3uqQPfm9eRlzv7p01yrHj9QOIgJGMexlJYL7w= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768378165; c=relaxed/simple; bh=3Gxg5Hr4J9OQ91mGE+xpPQ4JW4dYdbdKSmDAqlBDy8I=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=kVI8QUY4nOjYd6CBBFMCCzu/IzYrYSE+EJfmTNCL4o+NpX1kjNqX/aL1bxfW6FwDyT5Yb8pMphxezSeKx18uO8a70pyeOJ1uShzUWnQZFhdp9fn6YgNo2R3S7bGCQIvsFgig33ESMMrOXbBL+bE+C4btFv26VtvX2msLOay15DA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=nFnYT7EN; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=S/bidgjj; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="nFnYT7EN"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="S/bidgjj" Received: from pps.filterd (m0279866.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 60E7jOJG2081885 for ; Wed, 14 Jan 2026 08:09:19 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:date:from:message-id:mime-version :subject:to; s=qcppdkim1; bh=asPaEIWzLqvntL9JnZUOQmPd5F3UBxFlTc4 ky2SXtXY=; b=nFnYT7ENx/ugcnPj57TbLbG5LY9MVxRymJROsMuYR30uevcs9OE ANRU2nFG4HU8esSNC8paEBzG7DF5zKkYm5lN8z2Kx41762DbTE5my3GUaq+qoT0S mJR3uJv0TR64OHRaVUCRQWaMOHQv3dcevD6Phpufz4m8bNsrBaphRuqKo7mKxjxl MYpdC1qm5B6lI/2b1a2w1X/+b8dnEEBffCTJ82U1piwLLeb/ru+nvtiHTnTnV6Gq k0RQqifKJ+4FWrlUDTduZjMhHMfjAKWrjuSYhGjzyAFQNWbw8pfMfIXC84tCB8UO IUhRPlsD1MAoqXtpDbrYtIxMQy0HFjSQuuw== Received: from mail-qk1-f199.google.com (mail-qk1-f199.google.com [209.85.222.199]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4bnu58tcpb-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Wed, 14 Jan 2026 08:09:19 +0000 (GMT) Received: by mail-qk1-f199.google.com with SMTP id af79cd13be357-8b51396f3efso1646419285a.1 for ; Wed, 14 Jan 2026 00:09:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1768378158; x=1768982958; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=asPaEIWzLqvntL9JnZUOQmPd5F3UBxFlTc4ky2SXtXY=; b=S/bidgjj6XSmCYFUxBzMd7+NmUZGa/p+HSgqYq3Nq7EsqC/LghAe7fplmRVKzLaFWY bPkLtMeEKai/Vzv3JsSqa9fjO4SoVpgvBSwOe8wjWAOm+qgzon0LT/Tsaf81wmJgJpXv UwCfjo3c8rfXJM95uoOJj7gZ+3z10xfU/FWuwUfobwhTkKkbmHQX7l8kwkOA1JKiC+QX a2yOzPD4ST+abBhxKbOySsQS/y+d9gEOo+XDfyMO6zq5c7eDSWK/eUX0r4EJyp/pMrkC ISgj7W4bQBppe4ZunwZ12xprnv43BolpRlb6ISTgEcRmr3d1qprJxhrtzabjmqqTBr4F +M3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768378158; x=1768982958; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=asPaEIWzLqvntL9JnZUOQmPd5F3UBxFlTc4ky2SXtXY=; b=qYNsIefCwo35konJ+4h8YJgEzYbpBVndXzkpWl4zfgA2XzxyPRiqqN/4j+/s9uVgZN KsMBd1tcypp+aSzkZOK23Ml/6qWC9HxVHvNi52asvW768EB8DL2Ue0rY1n+jqkzIdjaM sv71BkV1cH4qhWbxNAJ4n3lP8OG5Bn5yXihpy+Jy/FVRLVX7/HJWEEzUiHBtXassrzOm VM2ycocQ1hpGNJUJyulAaHyiLV85X3EJWkNlfWyswi501BxT+Rw8xkXafsY08/bLzMml fSyJqMteu0KRi2TegCbUKXvSg4LRy00gyDfDC0vkngRjp0leVQqzx5NuuxlQf3SGpksb /hpQ== X-Forwarded-Encrypted: i=1; AJvYcCV+E4pFu/xcyIsOSPNItLP1wFRYlWQsCIc7BSyvdvFppEzx7ji8AjiKm1WUnc4koQrdFPeP5QBXCndk+KM=@vger.kernel.org X-Gm-Message-State: AOJu0YxBkikjWfactZyLocEoCKSszI0sNYSDTanaPL3dSbuXR0TkyM+O aRF/OVvyvfgK3qCo4FAuRkxaA2K/4GlM9Z2VGO+ZaszrgMyNWETYTtpC6NHBfbCTjHcl0UqaLiz zqKz82z5cRBTUc4TsFh7NL+p/j9w2vJPAjP2eetkj6khx7d2pXvRC6HdAu8E7akRAz2KtyFJUtg k= X-Gm-Gg: AY/fxX69pWShSYkK0T4EYqwCmKuY+8DPr2apxWTuIBps1quLhRZiqyfHHHqmXpXkwfj 9/Cqapv3GhR81XjTHiz0GiCl3kYpHn3SxyDcgNK5F6EHrEiWgoyvUsmPvH9N6psBpCaRg6S6rjP S3Gg3YbrvWeG9ram9Ua+zttrJvqTIIWxhOu4qgf7O4AJe/cw3i8QzS5lvmiwteF5gkAIaSnJiVw ggFkbhhmPR+oBiJwK7ZuNAOSi+nR5M1V0RrH7wtwXZbenxiKYlaKByKyoRs1f+U0l9fXKMcj0/3 Ye21x/KEKTBNxZ2IBqldPzU2mOTxutA2opYwE5Act22OwUnzsXllNfv7TkWbTD3qztPgOJLHOxq WpRK1KuBkKTTbs1AesvIa9eEfmPR8Bf86bKfMZQ== X-Received: by 2002:a05:620a:4411:b0:863:42ea:d687 with SMTP id af79cd13be357-8c52fbdbe67mr241604785a.78.1768378158452; Wed, 14 Jan 2026 00:09:18 -0800 (PST) X-Received: by 2002:a05:620a:4411:b0:863:42ea:d687 with SMTP id af79cd13be357-8c52fbdbe67mr241602485a.78.1768378157943; Wed, 14 Jan 2026 00:09:17 -0800 (PST) Received: from brgl-qcom.home ([2a01:cb1d:dc:7e00:8298:6f4c:8c3b:61e8]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-432bd0e16ffsm49816049f8f.12.2026.01.14.00.09.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Jan 2026 00:09:17 -0800 (PST) From: Bartosz Golaszewski To: Mauro Carvalho Chehab Cc: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski , Wolfram Sang Subject: [PATCH v2] media: saa7134: rename i2c_dbg() to saa7134_i2c_dbg() Date: Wed, 14 Jan 2026 09:09:13 +0100 Message-ID: <20260114080913.11960-1-bartosz.golaszewski@oss.qualcomm.com> X-Mailer: git-send-email 2.47.3 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwMTE0MDA2MyBTYWx0ZWRfX/IXACP5RGlkN FIMEXZ9Rlx9WIJyddZBMnNEtZ7laaljsY3iPmpGZloCK+kIyuRXRQBm5yWBuFOAcp3ZaHn2VDNF G5yyNSPGOguVpfZYA04sTRgAD0yqQA5pRUG0ZniPoEAS6MhAR9Nzy94Zv5SOMkNTQZTTggBGUbJ EkLuL5VUQDaoA7fnVWGYDecSS8ye52GdQaAeLkQIVnpfjn0wB8RVqSpAVJNv8fpthJ6/lVzb7ad OqSlybK6h046gh7uD43xp+4Av8xnQZRxNjR9wk/Btf3HtLM8mHri07WHp95PC3ge5DvIz7pzgjY C9BLOweqZWCWKbg5mJtXmSJZmZzpvhJXYu0YVZBW1GM+J1UQhxsFr0uqAUP3I3XFJQOBJ8zKVXJ C5c2A/95oh5ULR9d5fCAKuqbp/P60pABvC+TbcbfYxnxya7Fcl8JPxfrZ6Z5PFE4qr2r7+2gQ+B UMivhlYpKVNHr2dRXng== X-Authority-Analysis: v=2.4 cv=BZnVE7t2 c=1 sm=1 tr=0 ts=69674f2f cx=c_pps a=HLyN3IcIa5EE8TELMZ618Q==:117 a=xqWC_Br6kY4A:10 a=vUbySO9Y5rIA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=VwQbUJbxAAAA:8 a=EUspDBNiAAAA:8 a=QyXUC8HyAAAA:8 a=LDBv8-xUAAAA:8 a=Y985koWVPDaUQ3OhJb8A:9 a=bTQJ7kPSJx9SKPbeHEYW:22 a=DZeXCJrVpAJBw65Qk4Ds:22 X-Proofpoint-ORIG-GUID: 7UMBqzD6jHX6PWo26YopqyRB9MdLqGDd X-Proofpoint-GUID: 7UMBqzD6jHX6PWo26YopqyRB9MdLqGDd X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1121,Hydra:6.1.9,FMLib:17.12.100.49 definitions=2026-01-14_02,2026-01-09_02,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 suspectscore=0 impostorscore=0 priorityscore=1501 bulkscore=0 spamscore=0 adultscore=0 malwarescore=0 lowpriorityscore=0 phishscore=0 clxscore=1015 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2512120000 definitions=main-2601140063 Content-Type: text/plain; charset="utf-8" Ahead of introducing I2C-adapter-specific printk() helpers, preemptively avoid a conflict with the upcoming i2c_dbg() and rename the local macro in the saa7134 driver to saa7134_i2c_dbg(). Suggested-by: Wolfram Sang Reviewed-by: Wolfram Sang Signed-off-by: Bartosz Golaszewski --- We've started working on changes to i2c core that should allow us to eventually address the object-lifetime issues[1] in the subsystem. One of the prerequisite steps is to hide all dereferences of struct device embedded in struct i2c_adapter with dedicated wrappers. To that end, we want to introduce a set of i2c_adapter-specific printk() helpers[2]. The name i2c_dbg() conflicted with the macro defined in this driver[3]. Wolfram suggested[4] that since the i2c changes will not make v7.0, it's worth renaming the macro here to free up the shorter name for a use-case where there'll be a lot more users. It would be great if this could make the v7.0 merge window. [1] https://lore.kernel.org/all/aWYYZEPX-_1GfQtL@ninjato/ [2] https://lore.kernel.org/all/20251223-i2c-printk-helpers-v1-0-46a08306af= db@oss.qualcomm.com/ [3] https://lore.kernel.org/all/202512260206.C1TExj8d-lkp@intel.com/ [4] https://lore.kernel.org/all/aWYiJbtueA8g3srn@ninjato/ Changes in v2: - Use the "saa7134" prefix to stay in the namespace and avoid any future clashes drivers/media/pci/saa7134/saa7134-i2c.c | 26 ++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/drivers/media/pci/saa7134/saa7134-i2c.c b/drivers/media/pci/sa= a7134/saa7134-i2c.c index 04e85765373e..1164e91cbb7b 100644 --- a/drivers/media/pci/saa7134/saa7134-i2c.c +++ b/drivers/media/pci/saa7134/saa7134-i2c.c @@ -28,7 +28,7 @@ static unsigned int i2c_scan; module_param(i2c_scan, int, 0444); MODULE_PARM_DESC(i2c_scan,"scan i2c bus at insmod time"); =20 -#define i2c_dbg(level, fmt, arg...) do { \ +#define saa7134_i2c_dbg(level, fmt, arg...) do { \ if (i2c_debug =3D=3D level) \ printk(KERN_DEBUG pr_fmt("i2c: " fmt), ## arg); \ } while (0) @@ -84,20 +84,20 @@ static inline enum i2c_status i2c_get_status(struct saa= 7134_dev *dev) enum i2c_status status; =20 status =3D saa_readb(SAA7134_I2C_ATTR_STATUS) & 0x0f; - i2c_dbg(2, "i2c stat <=3D %s\n", str_i2c_status[status]); + saa7134_i2c_dbg(2, "i2c stat <=3D %s\n", str_i2c_status[status]); return status; } =20 static inline void i2c_set_status(struct saa7134_dev *dev, enum i2c_status status) { - i2c_dbg(2, "i2c stat =3D> %s\n", str_i2c_status[status]); + saa7134_i2c_dbg(2, "i2c stat =3D> %s\n", str_i2c_status[status]); saa_andorb(SAA7134_I2C_ATTR_STATUS,0x0f,status); } =20 static inline void i2c_set_attr(struct saa7134_dev *dev, enum i2c_attr att= r) { - i2c_dbg(2, "i2c attr =3D> %s\n", str_i2c_attr[attr]); + saa7134_i2c_dbg(2, "i2c attr =3D> %s\n", str_i2c_attr[attr]); saa_andorb(SAA7134_I2C_ATTR_STATUS,0xc0,attr << 6); } =20 @@ -160,7 +160,7 @@ static int i2c_reset(struct saa7134_dev *dev) enum i2c_status status; int count; =20 - i2c_dbg(2, "i2c reset\n"); + saa7134_i2c_dbg(2, "i2c reset\n"); status =3D i2c_get_status(dev); if (!i2c_is_error(status)) return true; @@ -198,7 +198,7 @@ static inline int i2c_send_byte(struct saa7134_dev *dev, // dword |=3D 0x40 << 16; /* 400 kHz */ dword |=3D 0xf0 << 24; saa_writel(SAA7134_I2C_ATTR_STATUS >> 2, dword); - i2c_dbg(2, "i2c data =3D> 0x%x\n", data); + saa7134_i2c_dbg(2, "i2c data =3D> 0x%x\n", data); =20 if (!i2c_is_busy_wait(dev)) return -EIO; @@ -220,7 +220,7 @@ static inline int i2c_recv_byte(struct saa7134_dev *dev) if (i2c_is_error(status)) return -EIO; data =3D saa_readb(SAA7134_I2C_DATA); - i2c_dbg(2, "i2c data <=3D 0x%x\n", data); + saa7134_i2c_dbg(2, "i2c data <=3D 0x%x\n", data); return data; } =20 @@ -237,12 +237,12 @@ static int saa7134_i2c_xfer(struct i2c_adapter *i2c_a= dap, if (!i2c_reset(dev)) return -EIO; =20 - i2c_dbg(2, "start xfer\n"); - i2c_dbg(1, "i2c xfer:"); + saa7134_i2c_dbg(2, "start xfer\n"); + saa7134_i2c_dbg(1, "i2c xfer:"); for (i =3D 0; i < num; i++) { if (!(msgs[i].flags & I2C_M_NOSTART) || 0 =3D=3D i) { /* send address */ - i2c_dbg(2, "send address\n"); + saa7134_i2c_dbg(2, "send address\n"); addr =3D msgs[i].addr << 1; if (msgs[i].flags & I2C_M_RD) addr |=3D 1; @@ -265,7 +265,7 @@ static int saa7134_i2c_xfer(struct i2c_adapter *i2c_ada= p, } if (msgs[i].flags & I2C_M_RD) { /* read bytes */ - i2c_dbg(2, "read bytes\n"); + saa7134_i2c_dbg(2, "read bytes\n"); for (byte =3D 0; byte < msgs[i].len; byte++) { i2c_cont(1, " =3D"); rc =3D i2c_recv_byte(dev); @@ -286,7 +286,7 @@ static int saa7134_i2c_xfer(struct i2c_adapter *i2c_ada= p, } } else { /* write bytes */ - i2c_dbg(2, "write bytes\n"); + saa7134_i2c_dbg(2, "write bytes\n"); for (byte =3D 0; byte < msgs[i].len; byte++) { data =3D msgs[i].buf[byte]; i2c_cont(1, " %02x", data); @@ -296,7 +296,7 @@ static int saa7134_i2c_xfer(struct i2c_adapter *i2c_ada= p, } } } - i2c_dbg(2, "xfer done\n"); + saa7134_i2c_dbg(2, "xfer done\n"); i2c_cont(1, " >"); i2c_set_attr(dev,STOP); rc =3D -EIO; --=20 2.47.3