Received: by 2002:ab2:6857:0:b0:1ef:ffd0:ce49 with SMTP id l23csp2583052lqp; Mon, 25 Mar 2024 03:30:47 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXXB+UU9lcRdaSdv3jMFthIXloB5BkS1oxRswnBj7u8duocXnLubi9Gn0M3BAJCPyfIwUVYuxb5RkLZfMUlR56Wv2wtJNjV4kGbrJmm9w== X-Google-Smtp-Source: AGHT+IE1VwQ4BlcCPU5kkJhqzWaGUMV6THEl63gxsxhUsvkk8xclYxzPUegZku9xU9DtYu/nJYjm X-Received: by 2002:a05:6a20:da9f:b0:1a3:4a22:5c5c with SMTP id iy31-20020a056a20da9f00b001a34a225c5cmr8913865pzb.5.1711362647041; Mon, 25 Mar 2024 03:30:47 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711362647; cv=pass; d=google.com; s=arc-20160816; b=cxXz2KGRXHTIaj00cphbH4GWbjipxp1VJYlvQzluliBWA42BpHabQ/ZUbL09mTZnM8 onvD3NunQnWANlChQZ3xzJ0JfNrKS7PvDLc5kOT788tGNEtLhWvJMiwU0fqY5ebNUvpY YQBPLo3Qpa/2jDtH/bDSs4uQS/W1Nglyo0v7nTwzXV0nD+DrPuKknH3s/6dXbnoxdaJL oZ60KJUd5ZXkYtGx+8nptiVtV0/BBgWTZ3Lb/Bq5KBqjXZfVtW06mSfWRDC7chamcJ4D BjOmEYtBKC9d4pD3x5YDqKoUbO0NoZp3XwzkyMRobR15A2bG6tn7NPnbfi/ch0LSVgLf 3iFQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=UvZ22nbi3oBrveYANpJX+eOm9E/q+JnPTDDNwgaPVZ0=; fh=PSqy2ZoKXxDSUh7CscPzOH26BIRwV8zVyVlNQPrGFxs=; b=xiizycNtwnBYq8lWguO3qPP+8lbgN3RgBw8FWSYqFhNzFDSdDulQH44iKjB+RjP0Em E6yJKQgzK7Jky/iTxGnFmD2zPNA4+7MeurOe4npiW/IJHeS8RHL0C3mcZC8V9oL/htoh 4gIAYGOezfqZ36oL8plvf/nA0+e8YP4KxQN2h+3KvjpLCViEPk95O38XNL/fSuqdm1i6 7ugdMS1i/TmhncpWCd7/CsXwD7uPVEiAeUs3/Q6IMKBmfeBvJ4iUWbZ5l7nNHpM0D8kj JBe1LZ9P6p5FlZn5SGze4QHyAZuuWtIEuJ0KJur/2JisDiT5KGQSrFnWtXuqUhN0+MoP 0SIg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@alliedtelesis.co.nz header.s=mail181024 header.b=lEQLBH0G; arc=pass (i=1 spf=pass spfdomain=alliedtelesis.co.nz dkim=pass dkdomain=alliedtelesis.co.nz dmarc=pass fromdomain=alliedtelesis.co.nz); spf=pass (google.com: domain of linux-kernel+bounces-116391-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-116391-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=REJECT dis=NONE) header.from=alliedtelesis.co.nz Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id j17-20020a170902c3d100b001dd46c442e4si4781349plj.270.2024.03.25.03.30.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Mar 2024 03:30:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-116391-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@alliedtelesis.co.nz header.s=mail181024 header.b=lEQLBH0G; arc=pass (i=1 spf=pass spfdomain=alliedtelesis.co.nz dkim=pass dkdomain=alliedtelesis.co.nz dmarc=pass fromdomain=alliedtelesis.co.nz); spf=pass (google.com: domain of linux-kernel+bounces-116391-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-116391-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=REJECT dis=NONE) header.from=alliedtelesis.co.nz Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id E41772A66E8 for ; Mon, 25 Mar 2024 10:19:40 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 4528812C535; Mon, 25 Mar 2024 05:35:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=alliedtelesis.co.nz header.i=@alliedtelesis.co.nz header.b="lEQLBH0G" Received: from gate2.alliedtelesis.co.nz (gate2.alliedtelesis.co.nz [202.36.163.20]) (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 6DF0213AA47 for ; Mon, 25 Mar 2024 01:56:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=202.36.163.20 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711331795; cv=none; b=u0BvkkSSuNzgWbS2xr5lot94Vomq++QEyzdCGr+ypubhQ1ug/08hWYf4EUHhNudLoqHRfWng2NLToJdV+DhVPesVWx1hnIW5aVOAETWtQaABc8BrVyy7cKWsVUur/7NQra2S5z1wTL8riFRdXiLB/EhExjaCpLPooivaJPrt73U= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711331795; c=relaxed/simple; bh=mx/VdD1hq7cRmoLLUg9zTXrB6nghO0otx5ehOvo8wJU=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=OYl03y7WJsnnw2hboaRnwcBqsPbm2STcBT28WjNhaKe+Btp1R/VI5oZqketZKbW5xJmMjzaJmeUDjs5etoY3cQ98b0SwdgocVzcW+2NQ2aCy8a3/wEHGAu/pjP90j8VGOyFf9GxNdkFgRnezX/yt0OYx293Wml2eAmr/ZI92OJg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=alliedtelesis.co.nz; spf=pass smtp.mailfrom=alliedtelesis.co.nz; dkim=pass (2048-bit key) header.d=alliedtelesis.co.nz header.i=@alliedtelesis.co.nz header.b=lEQLBH0G; arc=none smtp.client-ip=202.36.163.20 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=alliedtelesis.co.nz Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=alliedtelesis.co.nz Received: from svr-chch-seg1.atlnz.lc (mmarshal3.atlnz.lc [10.32.18.43]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by gate2.alliedtelesis.co.nz (Postfix) with ESMTPS id 42D7F2C00C6; Mon, 25 Mar 2024 14:50:49 +1300 (NZDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alliedtelesis.co.nz; s=mail181024; t=1711331449; bh=UvZ22nbi3oBrveYANpJX+eOm9E/q+JnPTDDNwgaPVZ0=; h=From:To:Cc:Subject:Date:From; b=lEQLBH0G0p5FfWe/jQ+cXxHsyUp3lqtUIqVcbjwtkWaB9OV5q+2B6GtUFautBhvaF 6Hm2H2VJMpUJ6U8VAcITw39qpvXEBWIkJwoi1d/bjj3p6MpptOD2pMLKn4yG8Gbb3Z x37wgkYLfck9N0JSToTqGF2zTA+wO0vW7HhiegChBUxQMkDDJQjeVOcysvMIrlViTX y3iW1457iQlK4O1tWztSthdXAD5Rb3H7ZDqm9n4BQxR3DJ1lwMooPtADa4yiC2osb6 tQ23RTRNzZ1yOHk7+VpgYSoumYI/gGNM0904kbe2N18Jz+QRLZtjEBsUQ61Y3+100j vGOunsPO0fjFw== Received: from pat.atlnz.lc (Not Verified[10.32.16.33]) by svr-chch-seg1.atlnz.lc with Trustwave SEG (v8,2,6,11305) id ; Mon, 25 Mar 2024 14:50:49 +1300 Received: from chrisp-dl.ws.atlnz.lc (chrisp-dl.ws.atlnz.lc [10.33.22.30]) by pat.atlnz.lc (Postfix) with ESMTP id 11EED13ED7B; Mon, 25 Mar 2024 14:50:49 +1300 (NZDT) Received: by chrisp-dl.ws.atlnz.lc (Postfix, from userid 1030) id 0CC26280A41; Mon, 25 Mar 2024 14:50:49 +1300 (NZDT) From: Chris Packham To: gregkh@linuxfoundation.org Cc: linux-kernel@vger.kernel.org, Chris Packham Subject: [PATCH] uio_pdrv_genirq: convert to use device_property APIs Date: Mon, 25 Mar 2024 14:50:45 +1300 Message-ID: <20240325015045.778718-1-chris.packham@alliedtelesis.co.nz> X-Mailer: git-send-email 2.43.2 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-SEG-SpamProfiler-Analysis: v=2.4 cv=KIH5D0Fo c=1 sm=1 tr=0 ts=6600d879 a=KLBiSEs5mFS1a/PbTCJxuA==:117 a=K6JAEmCyrfEA:10 a=kuWcMSrzkGJfJYRAjKUA:9 a=3ZKOabzyN94A:10 X-SEG-SpamProfiler-Score: 0 x-atlnz-ls: pat Convert the uio_pdrv_genirq driver to use the device_property_* APIs instead of the of_property_* ones. This allows UIO interrupts to be defined via an ACPI overlay using the Device Tree namespace linkage. Signed-off-by: Chris Packham --- drivers/uio/uio_pdrv_genirq.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/drivers/uio/uio_pdrv_genirq.c b/drivers/uio/uio_pdrv_genirq.= c index 63258b6accc4..772ab42a3ba1 100644 --- a/drivers/uio/uio_pdrv_genirq.c +++ b/drivers/uio/uio_pdrv_genirq.c @@ -23,8 +23,8 @@ #include =20 #include -#include -#include +#include +#include =20 #define DRIVER_NAME "uio_pdrv_genirq" =20 @@ -110,7 +110,7 @@ static void uio_pdrv_genirq_cleanup(void *data) static int uio_pdrv_genirq_probe(struct platform_device *pdev) { struct uio_info *uioinfo =3D dev_get_platdata(&pdev->dev); - struct device_node *node =3D pdev->dev.of_node; + struct fwnode_handle *node =3D dev_fwnode(&pdev->dev); struct uio_pdrv_genirq_platdata *priv; struct uio_mem *uiomem; int ret =3D -EINVAL; @@ -127,11 +127,12 @@ static int uio_pdrv_genirq_probe(struct platform_de= vice *pdev) return -ENOMEM; } =20 - if (!of_property_read_string(node, "linux,uio-name", &name)) + + if (!device_property_read_string(&pdev->dev, "linux,uio-name", &name)) uioinfo->name =3D devm_kstrdup(&pdev->dev, name, GFP_KERNEL); else uioinfo->name =3D devm_kasprintf(&pdev->dev, GFP_KERNEL, - "%pOFn", node); + "%pfwP", node); =20 uioinfo->version =3D "devicetree"; /* Multiple IRQs are not supported */ --=20 2.43.2