From patchwork Wed Sep 13 11:49:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 1833493 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=A3xTs8N+; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.a=rsa-sha256 header.s=20230601 header.b=JgrKBtTu; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=patchwork.ozlabs.org) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4RlzLH5VWMz26jQ for ; Wed, 13 Sep 2023 21:51:01 +1000 (AEST) 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:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=P72YnbHG277V28NmKzgEKK0LlAUPoVLvCPTcL5fKXi0=; b=A3xTs8N+TfgEuj VetKGe1/xXNwJdLxkL9ig87HYoMeYftGr2vQUWOMGQ/PxP2PTcaSyjAZytu4McTRNjF86WYx/gONg p78lJqoXYI5r52DYSJ3mo5SliW4Dj5gpD8Q34nXoXtYRswUZ1AhQ5z9D+0XN1ld4tMjfMvmYTAUB5 krj/E1xtElBLFSLMNfj06BhkFK5BsSG5HBJvb3va2w1ishfvId2oEiC+Cn510PXqiKlO0Kg2HyYn+ IeeJxzHldDl3tl33MMbMJcA32ZMJhJ98UiBLchzGLMC+oJrW4ZXodDVMCwwq3HTYUzcCyGkZKSyos ghbmtZ+UUiGg5oOzpPnQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qgOO2-005mWx-1a; Wed, 13 Sep 2023 11:50:26 +0000 Received: from mail-wm1-x332.google.com ([2a00:1450:4864:20::332]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qgONy-005mTD-0S for linux-mtd@lists.infradead.org; Wed, 13 Sep 2023 11:50:23 +0000 Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-401d2e11dacso5430845e9.0 for ; Wed, 13 Sep 2023 04:50:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1694605820; x=1695210620; darn=lists.infradead.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=ZfIOoxhDAqFwndjqT4NZlTiK/Oyr/4kFj6yAfQvO5X0=; b=JgrKBtTuqUSmEwBGpw6sFEn3zm9ldo/H3BxMvd0X100l7LlYeYgjKl9vRZ0OkBg7fM 7a3SJvRUe1HCz8m1Gi7bid9afH1wRUKRqSmidObGxNljCMsvf402/eebk2333XTxZa7Y qlag+Ykzak43G801B9gI8h89vYRsh7POx+p9f3TALTnRFWgNYQj7vxQhmx1yuHr3tvsg 4Lyo9ShSv9PeJpZ2B1Dvpv5xshUmbwwhQo0QtDJy6yAUpOBeZle5o+c6WVtGcTKiIUTT KKY3FSnb2jnxKBR7IOrpbXv42xfPhKDB20UlOE1zZd9pKVd1Xad3gH6PwsJdS+UNp9/d Eztw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694605820; x=1695210620; 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=ZfIOoxhDAqFwndjqT4NZlTiK/Oyr/4kFj6yAfQvO5X0=; b=wDpJE6Dn8CDoxquUHmBV1QXCKFr1C/hHAF/NlKrCdYZCH3TBuAWbLiPeyHR7sChE95 1r3SLNVCo1Y/SHaD9LFz8zi4W29Zxc/MjgrHZ0JpQavC2LQLvfpQ+IYUp/lsxchDCEer TEsudPd6jHqekxbd8Oob/0WSPS+ILlXf+ls4/Jdt0PxBUlUf7TUbnG4F3vSqd2wv5hbT dhWvlMiC70h8WgRQoM/PoB2yON5chl/oCE5lQgsxjH0VQVNyWKI9gB8OoCADQfm93kg/ Ld51NPw6qmfVvAvYsmFaa5TLBhvLethZJ8NgVWIfzYOnOhuII94Vx2PImtSUL+K0bLv1 2wZA== X-Gm-Message-State: AOJu0Yy2QYtVN01MH70dwW88tYFl1DOLc1QmRqit6aOHpJF7Pj0YKw6O eX01FeZjJwbNQYE3nmDTi3wWQQ== X-Google-Smtp-Source: AGHT+IG+tXi5eOBKUfSbBaQCtatc0omt4sm58mllw94JLePpeq53xP2hYKGlGG+xCKfpc+HJfdMuUQ== X-Received: by 2002:a5d:5b18:0:b0:31f:cc46:3db9 with SMTP id bx24-20020a5d5b18000000b0031fcc463db9mr1114110wrb.26.1694605820092; Wed, 13 Sep 2023 04:50:20 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:3b50:bca5:a754:7463]) by smtp.gmail.com with ESMTPSA id j14-20020adfd20e000000b0031fc4c31d77sm1932689wrh.88.2023.09.13.04.50.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 04:50:19 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko , Ulf Hansson , Paul Cercueil , Harvey Hunt , Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , Daniel Scally , Hans de Goede , Mark Gross , Heiner Kallweit Cc: linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mmc@vger.kernel.org, linux-mips@vger.kernel.org, linux-mtd@lists.infradead.org, platform-driver-x86@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH 2/5] mtd: rawnand: ingenic: use gpiod_set_active_high() Date: Wed, 13 Sep 2023 13:49:58 +0200 Message-Id: <20230913115001.23183-3-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230913115001.23183-1-brgl@bgdev.pl> References: <20230913115001.23183-1-brgl@bgdev.pl> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230913_045022_214763_279FCD3A X-CRM114-Status: GOOD ( 11.65 ) X-Spam-Score: 0.0 (/) X-Spam-Report: Spam detection software, running on the system "bombadil.infradead.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: From: Bartosz Golaszewski Use the new, less cumbersome interface for setting the GPIO as active-high that doesn't require first checking the current state. Signed-off-by: Bartosz Golaszewski --- drivers/mtd/nand/raw/ingenic/ingenic_nand_drv.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) Content analysis details: (0.0 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:332 listed in] [list.dnswl.org] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 SPF_NONE SPF: sender does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org From: Bartosz Golaszewski Use the new, less cumbersome interface for setting the GPIO as active-high that doesn't require first checking the current state. Signed-off-by: Bartosz Golaszewski Acked-by: Paul Cercueil Acked-by: Miquel Raynal --- drivers/mtd/nand/raw/ingenic/ingenic_nand_drv.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/mtd/nand/raw/ingenic/ingenic_nand_drv.c b/drivers/mtd/nand/raw/ingenic/ingenic_nand_drv.c index 6748226b8bd1..c055133c45fe 100644 --- a/drivers/mtd/nand/raw/ingenic/ingenic_nand_drv.c +++ b/drivers/mtd/nand/raw/ingenic/ingenic_nand_drv.c @@ -388,9 +388,8 @@ static int ingenic_nand_init_chip(struct platform_device *pdev, * here for older DTs so we can re-use the generic nand_gpio_waitrdy() * helper, and be consistent with what other drivers do. */ - if (of_machine_is_compatible("qi,lb60") && - gpiod_is_active_low(nand->busy_gpio)) - gpiod_toggle_active_low(nand->busy_gpio); + if (of_machine_is_compatible("qi,lb60")) + gpiod_set_active_high(nand->busy_gpio); nand->wp_gpio = devm_gpiod_get_optional(dev, "wp", GPIOD_OUT_LOW);