From patchwork Wed Aug 21 12:14:53 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 822841 Received: from mail-wr1-f45.google.com (mail-wr1-f45.google.com [209.85.221.45]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3E07315B54B for ; Wed, 21 Aug 2024 12:15:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.45 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724242506; cv=none; b=V5rGKCOwco+0KZwFS6Hbaz8J+iWoBXKuS65G0u+VT69cxKQ4KQ3s2zKkY9ep7IGz5jud1OMVim8jFxGhfT7M1AaRWoVj2oRCLIur6MFfln7vfVvHHbXFdhFxUrBMWJIgaB5TxbKBEN7DUkudURowk8V1oU1oBl/e90O0BFjQHTA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724242506; c=relaxed/simple; bh=/0VUObltFI36YwzvQUOf07lA1enaqqy/ADCqR56tepE=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=Y6RWxhsDSITFiO/rdQ9wVLG3792ISB1bFVtzHG8j/aQQ/SjLrvy1hUorjC9pRUa/0rlk07GHebPKpZQ/vuBbJjCH7QpyMqSqDjdaWBgs5DDubxVPswt2hx30WH9Xb47UBtBqgezF8EjNpkilR/zkbSktUvkH6MUIx/AOGDf/ycI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl; spf=none smtp.mailfrom=bgdev.pl; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b=Qu13vSEb; arc=none smtp.client-ip=209.85.221.45 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=bgdev.pl Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b="Qu13vSEb" Received: by mail-wr1-f45.google.com with SMTP id ffacd0b85a97d-36d2a601c31so3832867f8f.0 for ; Wed, 21 Aug 2024 05:15:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1724242503; x=1724847303; 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=eNEYv5X2eaQvG8N/4e9judfOPIHJ3R5WVAeQVepl5OU=; b=Qu13vSEbHq3fytHJ+gtPGd5SNOeFcu417KeCSh9+i/mm75eG3X0/rEpd9WS823dUQ6 +5rwADpGrmOWzDzdWqPQQiFS37GK2Yef08D1zz4klRpMEfNsJ3GJrbqbUeRZCO18r2HR 3OXZLSBPhm7qldjLvbuqgJswC1hA+TkVOTr12S2uQtBxJNiwMcx4jRMs4J2LCbj4R1eh TThqSxX3GJg3sFQTJpF2K6hpoTIby95dRIiKfOMrRKJB3TvYnSIXSBmjP79u3JQHwVho 8cDU+5Qaqzt1ntKN4C3+hoZKJkKx/Ilo3tD2kxV4n04qwMFR9YxOncPIvL2jxOj78ACH JWhA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724242503; x=1724847303; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=eNEYv5X2eaQvG8N/4e9judfOPIHJ3R5WVAeQVepl5OU=; b=q0+zUqEIndeaouy8tLdOHeVhN+Bn62sdGZdHdplQQHPOK9Xi1VBgIbYvCi0aGsHHkX uX2U7RdXu5qmTdFMIl0vwvt9o6YOELd9yFgGj0sKdD3mCpZWuzRo8PK/SyiEYwaR82i3 VHLvS604YNRfpFkQriROt63oLEjA5bL3Vc2rRdmqFiiVNO9KjrcgyuBQ6mglVKnh9r9F 2YtkilA6NGIP29jw5EDLwaRUgWMWUHNTh/vT00dyrjdfXNHoxXbFF2lgBv1b9sRUP3J2 SOW63fsqfs7W0hwLdNDYdsIjNBLrFC8NdRe3T1gRYQXxSste+zIk2JALPS0Gyf58vUtX 4cnQ== X-Forwarded-Encrypted: i=1; AJvYcCV+Wj/TAVUoAuA8O+l3bJBedBLUxBlRuo+Zh1zawVkmmqv2jzTpIxobMgmbz0DPO+iOXNZIfGT+rzRt@vger.kernel.org X-Gm-Message-State: AOJu0YwNYAktlNYykmznHrYDxHJMe86KxUObLaNdKQV71GcrMSPrYR6u suzVnIwZae5tk+2YWliZ64hRAFbQhIKbdWP81rHv0FLf99ISBEuQvTBB5ofCKm8= X-Google-Smtp-Source: AGHT+IESkq5T2JFkI+DO8A4yBDzS+8in4n0X7cqNUYMPHMjQFQFHAT6eBufSmUam01sj30Xhz3cNcg== X-Received: by 2002:a05:6000:196b:b0:371:8bc9:1682 with SMTP id ffacd0b85a97d-372fd6f1402mr1455433f8f.33.1724242502824; Wed, 21 Aug 2024 05:15:02 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:dc:7e00:42a6:b34f:6c18:3851]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42abee8b43fsm23056595e9.12.2024.08.21.05.15.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Aug 2024 05:15:02 -0700 (PDT) From: Bartosz Golaszewski To: Alban Bedel , Linus Walleij Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH 1/4] gpio: ath79: order headers alphabetically Date: Wed, 21 Aug 2024 14:14:53 +0200 Message-ID: <20240821121456.19553-1-brgl@bgdev.pl> X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-gpio@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Bartosz Golaszewski Put all headers in alphabetical order. Signed-off-by: Bartosz Golaszewski --- drivers/gpio/gpio-ath79.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpio/gpio-ath79.c b/drivers/gpio/gpio-ath79.c index 6211d99a5770..be2952fdae3b 100644 --- a/drivers/gpio/gpio-ath79.c +++ b/drivers/gpio/gpio-ath79.c @@ -9,12 +9,12 @@ */ #include -#include -#include -#include #include -#include #include +#include +#include +#include +#include #define AR71XX_GPIO_REG_OE 0x00 #define AR71XX_GPIO_REG_IN 0x04 From patchwork Wed Aug 21 12:14:54 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 821087 Received: from mail-wm1-f43.google.com (mail-wm1-f43.google.com [209.85.128.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9A97E166F19 for ; Wed, 21 Aug 2024 12:15:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.43 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724242507; cv=none; b=V76CSDFTKh5OfHzidj+IRV46aEaX7ehImHwh1vhqL6K5PRfb+ybaK0UjHjnjE7cOEOTiXvNRnUj7LwQDhLOXfetPvO8KbkKDr+LRb58S+U47XG2/edAMb3VHzYX/es9KXl8dGrI/LtMsoO0g8aL+H2U0sXHJ6zBD0RUeVix/77U= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724242507; c=relaxed/simple; bh=8XDdi+wKeN16H5QYAJ149FGzvNNOIx3CUjldgIHNaPY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=REIIDQNW0vKGhfWSZ+xBiHkSfdEOSem69cagsu1jU/dr6RPzi8SEOUcF4qvM8IdtHyFKZ2gt24bKIcMdy607TBFDyooxrB5NjtfMsCYIMMpMIzm/1tCM43rvrpV6Vy1C/rk9T7W6+4Ni/az8/NIn0PYpGG8R1BvmK8VJ7wSLoJE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl; spf=none smtp.mailfrom=bgdev.pl; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b=IEWPR/63; arc=none smtp.client-ip=209.85.128.43 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=bgdev.pl Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b="IEWPR/63" Received: by mail-wm1-f43.google.com with SMTP id 5b1f17b1804b1-428e0d184b4so51313335e9.2 for ; Wed, 21 Aug 2024 05:15:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1724242504; x=1724847304; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=xTz300t/luXT8zpf6sUHvk2i6OLc3SxIx0fProJbjig=; b=IEWPR/63I8bFdt7IJq/3BWLmrMi/wn6+aid+fDWkgy17oRZsSm/E1RrozMdC749IrQ +RJhk779W8yJsblfuBBQZ5cMiYfp+zWIZfgfzOVse/rSHtV46/B59Sap/o6vsp9urw9+ FfGLaanszgBrbWUW+MLOOOkBf3Yv4GBmFDFW68eCOAQFtGgyWa9o0RslbP5SBVOE5eN9 sWRfFQq7erlJyzXkwd5NwDrXFU7JXTUrIT7ojWQHMKCKREXsxRBQUybrblBaCpt5igUl fKppcd3ntthMZygxS7Zq64zTjZx4mtMWM6DwcODNNMTWRpuKpJpz0wVaEFbMmE4KiTih hNLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724242504; x=1724847304; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xTz300t/luXT8zpf6sUHvk2i6OLc3SxIx0fProJbjig=; b=hZVWSD5I2bBb6PreaGSI1b0AOJjpUrDwSvremZf+TSNQf6lVpRNMBx+kkeqqpJqdlw boCDWY5Wq1qI5oHbKT1u3T8soSmqGTbMidP1TNytZIx9gvsPlg8cb00D4h54Jx43fhZJ m/5MqApeKOCml45Qtfhk0dYk1Gl4hMX3VkuQ6roTlEpn8Wyv5fKNtGgwFqfDuqC2r720 IjY7gB2zim4a+uatFaZ+4Kk9Jf8dDAV3mE1uF+FwCgfKIkJfRyKV+T/niQgAv094+rHs rmwURCfmA/LJjT6ZNvtco2anhci0pM9IQAQ47x4jgloKQR4/l7/jZCqigUi80rndsF8s QSSg== X-Forwarded-Encrypted: i=1; AJvYcCV8z0QhltdmIvfyH4f2CLw7VDbQEbZdWQilmjfsghIPYoEjZmDxQ2GdcLxCeyYET9WkFp+KTcKbrHfS@vger.kernel.org X-Gm-Message-State: AOJu0YxdlTeiJsKWEiHKqqCIl4QCypamj0dey+Bb25B+C0DIRUskhQSZ +5k+oJdcgtVQuuhaomvHQo9g7SpTSotroh3Kh9W2ZqsuWTF9IA55fDVAs+nuua4= X-Google-Smtp-Source: AGHT+IFNhN49sYxGRaKV6Ju/INhyn5+tc7rma2VMhAE1dPfKeHdY4KqapcmU/kumSKGI9L9AWQLO/w== X-Received: by 2002:a05:600c:3d0d:b0:426:5c9b:dee6 with SMTP id 5b1f17b1804b1-42abd2449e2mr15984185e9.26.1724242503495; Wed, 21 Aug 2024 05:15:03 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:dc:7e00:42a6:b34f:6c18:3851]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42abee8b43fsm23056595e9.12.2024.08.21.05.15.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Aug 2024 05:15:03 -0700 (PDT) From: Bartosz Golaszewski To: Alban Bedel , Linus Walleij Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH 2/4] gpio: ath79: add missing header Date: Wed, 21 Aug 2024 14:14:54 +0200 Message-ID: <20240821121456.19553-2-brgl@bgdev.pl> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240821121456.19553-1-brgl@bgdev.pl> References: <20240821121456.19553-1-brgl@bgdev.pl> Precedence: bulk X-Mailing-List: linux-gpio@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Bartosz Golaszewski Include mod_devicetable.h for struct of_device_id and its helpers. Signed-off-by: Bartosz Golaszewski --- drivers/gpio/gpio-ath79.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpio/gpio-ath79.c b/drivers/gpio/gpio-ath79.c index be2952fdae3b..7f9e66d75c8b 100644 --- a/drivers/gpio/gpio-ath79.c +++ b/drivers/gpio/gpio-ath79.c @@ -11,6 +11,7 @@ #include #include #include +#include #include #include #include From patchwork Wed Aug 21 12:14:55 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 822840 Received: from mail-wm1-f42.google.com (mail-wm1-f42.google.com [209.85.128.42]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 30787188909 for ; Wed, 21 Aug 2024 12:15:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.42 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724242508; cv=none; b=qCmCtHiIiWXxcgUbWEV+tA1/vRtHhjB5VIuY384Lcmbz3z0UOs20+WaOF525S3RJRounFQdYRg0XUL530miAmKXfsfqBzN435gxjiE3AZ0nKH54zYfIHDOqelzLVFIK4zLdIl36siZVDfcLJQvmul5FWmsYVlh8QaC6hlZpO65I= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724242508; c=relaxed/simple; bh=MvPZYChaSu48xcGhe0UV0wtQ2Wcl98SijA6Nj/8YE1w=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=G44qzKL0bLJ66MQ13NOlkkbC8ON4nYwKkPTAhCfwMvqZvttU2b9i7nMUsGNva25u91oy08Qt2yAZMDVXo9TF7llYoZfjxl4nJwz0DG+a875mK7ZBgiJp0TOg8TY/3UFXh6ZUWbQPyAxB7HhjLrBxwvTpXtHAt8pOV13O3PWqguw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl; spf=none smtp.mailfrom=bgdev.pl; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b=zBEyXfb9; arc=none smtp.client-ip=209.85.128.42 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=bgdev.pl Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b="zBEyXfb9" Received: by mail-wm1-f42.google.com with SMTP id 5b1f17b1804b1-428119da952so53699645e9.0 for ; Wed, 21 Aug 2024 05:15:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1724242505; x=1724847305; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=W522iQjD1OPMlrDTE09654YKgrbKn4PGID5p31o6cSk=; b=zBEyXfb9yrmzA/bRUFQrLyyWY9YOK/aA8W29BSs9KTry+UWXCABrCdrqdig/6hUgmD A8pTnJ8BpE0SIKJDrLKEfCh0+xhM8e3KIXX7YN7GFdiMV70+9lnDwiR/0/d9eZyQbad+ vswi+uiugVEGU/0kaEUtYUrhnG0yBZo0fEJZdsdXuJOxkgNp3wNGJS1GPgGDFqNbGkDe 8aJf4ugz5TAYUjfQv7N/VRgQCKiUBkMo2ZMw0XWd4AfccX9O1U+B8x+0T+xXBq/YnjSF ztb2cwxYva3ht7+Ln4rSU/mXBKyRgxpdkH7luxvhy0m7zYxOcg7EsdWVb9Rq3z2wJiz7 YQmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724242505; x=1724847305; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=W522iQjD1OPMlrDTE09654YKgrbKn4PGID5p31o6cSk=; b=r3zK1mWmQhJCHz/DBpjzM8bwOmALtft1TbQcMvoLq/pIeDGh54Ksedq8tpj0msrBip 14vBmmy89m0NOTTu/awLyCh2yyd9FqQEOMMolzmfsVlGY0FuuM+mUrieq65WbB1Ewb6d jVeS53fRbKkhUY0wnA3SYyIM8oh4tYi29MszpJBYhu55AjEoqYSG8tAn6MCRVfZcL2bU GpB90ti6rjvC+rwlCmEiLp9OPxn88GD1UBvgT6IiJqikpW7hXWtJGJYAHZpGxQ2uFmDO dUxGh32qdEa5w19lfbqr2yU32/Q7r7dQse4SqoczboJ7wXv+YzUPKbdccirjqTqg1RVt z7Dw== X-Forwarded-Encrypted: i=1; AJvYcCUooGWF3qXda7csCyI/1GNpfoK7qtDO0Rkw4Ds/lizXYxmhIMGIP+8/VAc/AG1E0KB53F9aDOF6tWYT@vger.kernel.org X-Gm-Message-State: AOJu0YzbBHVSK+o1/f+6oK6tdHtmhglKxuZfO/P0z28A5vnojiaBlxLe uYfIXpV8jgq6Vp9iiK9sKJAvT7rh17tK0OAuXYCw+dX4SUvm+Nn5FdDJiAV0b5I= X-Google-Smtp-Source: AGHT+IGbshlM6qk4FCeTg3pBRUAoxPkSAZLN+Uo1JQuNMKBUoB3kMWjeaX6lkQDLWbQUXu+jw6K60Q== X-Received: by 2002:a05:600c:3b86:b0:426:5269:983a with SMTP id 5b1f17b1804b1-42abf048867mr16517455e9.8.1724242504989; Wed, 21 Aug 2024 05:15:04 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:dc:7e00:42a6:b34f:6c18:3851]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42abee8b43fsm23056595e9.12.2024.08.21.05.15.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Aug 2024 05:15:03 -0700 (PDT) From: Bartosz Golaszewski To: Alban Bedel , Linus Walleij Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH 3/4] gpio: ath79: use generic device property getters Date: Wed, 21 Aug 2024 14:14:55 +0200 Message-ID: <20240821121456.19553-3-brgl@bgdev.pl> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240821121456.19553-1-brgl@bgdev.pl> References: <20240821121456.19553-1-brgl@bgdev.pl> Precedence: bulk X-Mailing-List: linux-gpio@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Bartosz Golaszewski Don't use specialized OF accessors if we can avoid it: switch to using the generic device property helpers. Signed-off-by: Bartosz Golaszewski --- drivers/gpio/gpio-ath79.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpio/gpio-ath79.c b/drivers/gpio/gpio-ath79.c index 7f9e66d75c8b..211faffbef32 100644 --- a/drivers/gpio/gpio-ath79.c +++ b/drivers/gpio/gpio-ath79.c @@ -8,12 +8,12 @@ * Copyright (C) 2008 Imre Kaloz */ +#include #include #include #include #include #include -#include #include #include @@ -239,12 +239,12 @@ static int ath79_gpio_probe(struct platform_device *pdev) return -ENOMEM; if (np) { - err = of_property_read_u32(np, "ngpios", &ath79_gpio_count); + err = device_property_read_u32(dev, "ngpios", &ath79_gpio_count); if (err) { dev_err(dev, "ngpios property is not valid\n"); return err; } - oe_inverted = of_device_is_compatible(np, "qca,ar9340-gpio"); + oe_inverted = device_is_compatible(dev, "qca,ar9340-gpio"); } else if (pdata) { ath79_gpio_count = pdata->ngpios; oe_inverted = pdata->oe_inverted; @@ -276,7 +276,7 @@ static int ath79_gpio_probe(struct platform_device *pdev) } /* Optional interrupt setup */ - if (!np || of_property_read_bool(np, "interrupt-controller")) { + if (device_property_read_bool(dev, "interrupt-controller")) { girq = &ctrl->gc.irq; gpio_irq_chip_set_chip(girq, &ath79_gpio_irqchip); girq->parent_handler = ath79_gpio_irq_handler; From patchwork Wed Aug 21 12:14:56 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 821086 Received: from mail-wm1-f47.google.com (mail-wm1-f47.google.com [209.85.128.47]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B63051531E7 for ; Wed, 21 Aug 2024 12:15:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.47 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724242509; cv=none; b=YeQiOs12uBLPRCOuOVM9B0ZUiQY3uURVYnVTssjwiRBjxjkfphQJzn2vBhfElfVp2IBtaHZS+b2fJeDJdI8Cu3RUZeXUC8EiQTbeJiqlqIzk0WVWhcbKJkL4NpANqTlzcooRN1otCvsRjoLdI6izpvgrsXngSMaWwuCWLr4MZYg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724242509; c=relaxed/simple; bh=3H/WqiAo6uqFZQE1lRkQCi5RepQKfb9s+lHlguhqzZ0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=XjMqqBhFREtVmpw81HOpeUYCkgEIDVpnr4hEs2uyJJn67fNxzkwHICZwJbUdYxX7set61uGq5OeUwuX9mJDfzgwM92BNDZ91NdX8+81DVoFk/ckktJ+FldVqVjor7ZPyAJljMZj+k6rR3JlLBaa91fc/iOoFHvn5Af7fwT+W7g0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl; spf=none smtp.mailfrom=bgdev.pl; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b=LIjN60aX; arc=none smtp.client-ip=209.85.128.47 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=bgdev.pl Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b="LIjN60aX" Received: by mail-wm1-f47.google.com with SMTP id 5b1f17b1804b1-42808071810so53632075e9.1 for ; Wed, 21 Aug 2024 05:15:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1724242506; x=1724847306; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=/2g23GRxkgie7TFHi4GQuGeOQtGfBjr5Jypy20f9X7c=; b=LIjN60aXa5Fsou/2rs3AH+1MJE6URXg9AQLarLght1t/uwESBEYeisYdbUVO84wHRu 67JvLL/B5s0nUb0Z1idLAuRATfEvpT/xM+awVPyO9o49Gg1cu7pseDb9W4qy094Bt1/T 6+nei2zkElRVqkM94uUqRhhhUWL36Nosefp6qnp0hN/Vj7ceElx4xQJ6VgrZJhqH8tyJ 6njRiCEWQgyjUr+0NKFUi1UwTzc60LygoDK9JRCtoL0KJ6zwd7wfQIUMOwIH6T8F3x2H +XmXa16nISMlrSwF/Ppst7/7+t+ec8J+J4d576xPhPI3O9vSWrhF6lTQzIbcY+MMHqP5 fxAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724242506; x=1724847306; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=/2g23GRxkgie7TFHi4GQuGeOQtGfBjr5Jypy20f9X7c=; b=DcpRA72h0BWiZ1MVM7qmDJ9Ud4y0ZxxN6240olOAnR0MDv8VzusRvIUFL58Ij/ocI+ 8f+nNxrLdgwRyubyIHrAZ6CJPpYjtImT9AG3NpQj36pELLBLgX0ZlmASYXKCMva1lnx9 7goPfMPRtl/XC5zEm0YB7w3hUUZf2tqAC13eKj0ldopyrWwwhaeKItOQJqp3nnzVkLhR FGtpuPXMTTaRz8FXMSpapv+bDYbhbMIXw/NKvQCnZV+ViX4A+651uyNazy5e6YLQ3Nh7 GLxxb+ZxanymlxJm/08nBiNOx+J8No/rMxzoXMCO7ZkurzyQIFwnpyhvNRVe5vfFThBl AuXg== X-Forwarded-Encrypted: i=1; AJvYcCXaYCeawV6aop1yVpliCfAgk/6jD6bEE29qObsM+H9A8+1SNm2iCsOMyRoF891KMLpN0VIIMCTzR8e3@vger.kernel.org X-Gm-Message-State: AOJu0YwF3UN6we4um5BFSoHDoTO0LNz2LxHaAVlXedfkgQnYwA54adkt 7VsSctqubzbnmGTmSFej7ym6SYmqx08CvYalM/34yaM7EH3lV1uUZVtfc36KeHQ= X-Google-Smtp-Source: AGHT+IHNB0bMBHu5uN2TeLkLjvGSPPoCscd1V61ttq3FLFZReTCP+bj6itZle9p3KiNgSz4rqRCKmg== X-Received: by 2002:a05:600c:354f:b0:426:5e91:3920 with SMTP id 5b1f17b1804b1-42abd245744mr20584995e9.29.1724242505674; Wed, 21 Aug 2024 05:15:05 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:dc:7e00:42a6:b34f:6c18:3851]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42abee8b43fsm23056595e9.12.2024.08.21.05.15.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Aug 2024 05:15:05 -0700 (PDT) From: Bartosz Golaszewski To: Alban Bedel , Linus Walleij Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH 4/4] gpio: ath79: remove support for platform data Date: Wed, 21 Aug 2024 14:14:56 +0200 Message-ID: <20240821121456.19553-4-brgl@bgdev.pl> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240821121456.19553-1-brgl@bgdev.pl> References: <20240821121456.19553-1-brgl@bgdev.pl> Precedence: bulk X-Mailing-List: linux-gpio@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Bartosz Golaszewski There are no more board files defining platform data for this driver so remove the header and support from the driver. Signed-off-by: Bartosz Golaszewski --- drivers/gpio/gpio-ath79.c | 22 ++++++---------------- include/linux/platform_data/gpio-ath79.h | 16 ---------------- 2 files changed, 6 insertions(+), 32 deletions(-) delete mode 100644 include/linux/platform_data/gpio-ath79.h diff --git a/drivers/gpio/gpio-ath79.c b/drivers/gpio/gpio-ath79.c index 211faffbef32..de4cc12e5e03 100644 --- a/drivers/gpio/gpio-ath79.c +++ b/drivers/gpio/gpio-ath79.c @@ -14,7 +14,6 @@ #include #include #include -#include #include #define AR71XX_GPIO_REG_OE 0x00 @@ -225,9 +224,7 @@ MODULE_DEVICE_TABLE(of, ath79_gpio_of_match); static int ath79_gpio_probe(struct platform_device *pdev) { - struct ath79_gpio_platform_data *pdata = dev_get_platdata(&pdev->dev); struct device *dev = &pdev->dev; - struct device_node *np = dev->of_node; struct ath79_gpio_ctrl *ctrl; struct gpio_irq_chip *girq; u32 ath79_gpio_count; @@ -238,21 +235,14 @@ static int ath79_gpio_probe(struct platform_device *pdev) if (!ctrl) return -ENOMEM; - if (np) { - err = device_property_read_u32(dev, "ngpios", &ath79_gpio_count); - if (err) { - dev_err(dev, "ngpios property is not valid\n"); - return err; - } - oe_inverted = device_is_compatible(dev, "qca,ar9340-gpio"); - } else if (pdata) { - ath79_gpio_count = pdata->ngpios; - oe_inverted = pdata->oe_inverted; - } else { - dev_err(dev, "No DT node or platform data found\n"); - return -EINVAL; + err = device_property_read_u32(dev, "ngpios", &ath79_gpio_count); + if (err) { + dev_err(dev, "ngpios property is not valid\n"); + return err; } + oe_inverted = device_is_compatible(dev, "qca,ar9340-gpio"); + if (ath79_gpio_count >= 32) { dev_err(dev, "ngpios must be less than 32\n"); return -EINVAL; diff --git a/include/linux/platform_data/gpio-ath79.h b/include/linux/platform_data/gpio-ath79.h deleted file mode 100644 index 3ea6dd942c27..000000000000 --- a/include/linux/platform_data/gpio-ath79.h +++ /dev/null @@ -1,16 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0-only */ -/* - * Atheros AR7XXX/AR9XXX GPIO controller platform data - * - * Copyright (C) 2015 Alban Bedel - */ - -#ifndef __LINUX_PLATFORM_DATA_GPIO_ATH79_H -#define __LINUX_PLATFORM_DATA_GPIO_ATH79_H - -struct ath79_gpio_platform_data { - unsigned ngpios; - bool oe_inverted; -}; - -#endif