From patchwork Mon Feb 5 12:44:58 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770294 Received: from mail-wr1-f47.google.com (mail-wr1-f47.google.com [209.85.221.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 DF50B1BC57 for ; Mon, 5 Feb 2024 12:45:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.47 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137121; cv=none; b=UYs6KF292aV6JSeaH54WCUEU+YuXmaOU3KB+/LuEU+KUlxDGNc/jif3tVH7nCev6yhHMyWhv3HGaUJ6DVycR+K0tWqoLtzV0gEWOlh7E1HjEBnECSFbmXzDp3v/SNL/WmCv4zXC+fDiSJQGCcOP/uAKy6FpokCZMlrB4Mx046Ns= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137121; c=relaxed/simple; bh=w5JFDx3igBQ6hCvWUpDTLodih1IhDobo9CBbUVJNHT0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=NQQKvogLJM88/XN1e+jr7crNvR5GEw4cc61+kK45epgB6prnd52ewGCIXR+jMo1r12Ifd6DLcyUWGdd5VabDa8HR4qMdRdvlgGb1EB65/I33+SVlvvyWWL9l3OTm6Nm47vxwtbcfyBWUq9tamePUA7axa89nK4QxNanczvaRywE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=AfrLPn19; arc=none smtp.client-ip=209.85.221.47 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="AfrLPn19" Received: by mail-wr1-f47.google.com with SMTP id ffacd0b85a97d-3392b045e0aso2446861f8f.2 for ; Mon, 05 Feb 2024 04:45:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137118; x=1707741918; 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=G5ZHz3RUkQzpbVKYtYrrDh0U5BmbIjj4KbeJaOU/Fns=; b=AfrLPn19rAnlYjgMSt3zmwaoRTjgrHtP6XChKelZ3zrZNcueRhteLqgKypIdnUe972 cVupn9gFODR5HHxQO7lQFSPHs596k0X1leFfVQ22iy/fQTs6ya2FEbdvEiNh3czJ6hxz 0UI7L870mEscceHvFVzz0n+7FL6u0pjMcmOfgHHWC2yd5F5NQ/GGJAI0keVdYPGiILN1 zkntVg/i6E7na+nmjzj2H6F9Lur+T02CEBYYsdwM95GRpJ2TWYVDxwBasKkVBzoC97sO DKFOGY/XjcxZ3Bi64TB8lJ0CseIqLbx3zB0K0n3Us1yvyNP2ph/WsOO5Gaio17+r6UPW fgdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137118; x=1707741918; 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=G5ZHz3RUkQzpbVKYtYrrDh0U5BmbIjj4KbeJaOU/Fns=; b=EU8WJVh+7Kh4vbrC+ijoCygnUVDlWoYkgqF6ojgK6X2Rhg9+FHOxHOoUOADkrXVJAB Wd1RGLsJTW7dkpjYGCSDerCpMVnsczZF0fg1rCi6+/ePZ7yBlubJw9AI1sGjUP8Xw64u LwFg4yOlUHbMWD5cQYOiQjhFZo5syVjRmEd0Hv+22Q4Qp2T/3fX5V2/cpNPDVDn1nenM vcE5+Q+CqMv24zjXbjjUIDkJAotNZuYDW+zSMCvuBCekp4yU16xrvIR+wQl/PXmlb8Mj 6EOsmDUVO9tKUI5cK9p4pSiW4aCyutMd9jwN+jsdG5kGm5rjyRJmjiCCAYBTMx8jawo9 WRQQ== X-Gm-Message-State: AOJu0Yz2hVq5/enPlTsVWF+bN+ENIQphKbq79GTQ+4qoL6dppv9LdNu/ x5KZuPy3o8Sf499kiR61shtUblgzCuI3K8meWdVjYMzl1/uwA1TJ5TW0Gyx5l1A= X-Google-Smtp-Source: AGHT+IH2g+aR/d3Fae3kdapdUimxpiado+1l+RHT/8yqZSKFvLAV9z7ZolUfNyqRIwCk2qjcXVUgDw== X-Received: by 2002:adf:e5cf:0:b0:33b:271c:7816 with SMTP id a15-20020adfe5cf000000b0033b271c7816mr5677447wrn.34.1707137117995; Mon, 05 Feb 2024 04:45:17 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCXtbBtwOp4puWrLL5c/VhRl/CPpo7l2wIBvMapxm89/G7uxlduwkxRUThQZ0QEbczFrOy48ou7ofI5BCEX40lsslzCFFjvWAjmuzT8DjVAW+riZ9tU5nE//rSfXikq78EmH1ppYoo96wXmU/vYmhOfuAEGjukCYaq+1IxulzaxLMtMl4koGrrABfSCPx1y73OJTy4thv/5CfAlkB6PpHktM7bLpjIcgTC+ms0jQsrpjKsj9eQwKOVq0sm7DJdOMsZb5s0mrIEMDqkFSI4+F7+Q6ZfhXh5Lrvc2+bBv2CzNSlKm8k8btEv14J1iv2H7Vq1pmzW9ipVGP8BFDGuKP8S0GQwg2uVB9LpURT2M7q9iuqF4qkZPx4OlNFnn9kqqrpwFtWe2qqbPhI5ju/hL9LSwSgZFo2z8/D82IwbTrrmKlgcSY9fveajc8V715ICpC2OfquSxvtrDUPp3Tj9qMg4DRZf1JBbDbcYaDoqzWM4SOw2SUaiu5kmkqiu5i1Q== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:17 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 01/16] spi: s3c64xx: explicitly include Date: Mon, 5 Feb 2024 12:44:58 +0000 Message-ID: <20240205124513.447875-2-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 The driver uses readl() but does not include . It is good practice to directly include all headers used, it avoids implicit dependencies and spurious breakage if someone rearranges headers and causes the implicit include to vanish. Include the missing header. Fixes: 230d42d422e7 ("spi: Add s3c64xx SPI Controller driver") Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 7f7eb8f742e4..c1cbc4780a3b 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -10,6 +10,7 @@ #include #include #include +#include #include #include #include From patchwork Mon Feb 5 12:44:59 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770555 Received: from mail-wr1-f49.google.com (mail-wr1-f49.google.com [209.85.221.49]) (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 580B11BC5C for ; Mon, 5 Feb 2024 12:45:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.49 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137122; cv=none; b=nzZTmFisACalIQXQ1kVGGyrFpBb4uzrJ0B0NRZItiqD1KY52UtEzxXBNCuPWQfVb7j5fr94JIFmGjt2OZb7lKEwRJb4zzxgOvvt4Ed+Kokbrvlu1jl2P+c0U4/Y+96CT3lkkKuCjh7kHIjb3tEv4Mvf6zhlQaCNgN4QiSAsCntU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137122; c=relaxed/simple; bh=5qYcJnFoULZlrS/gcnahlbnYI2pJkSgG/5PVWkskUyE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=tpGxy6OCyKGil6GvkQAJfOZCfEMOL7HoimPbi4I8wYzWWlpZWiUiYNZ5LU4glbRzp4g+Thz/KfpflBKrOypxNw4hjWk8AYz/IiALwJsh4fLawxi6g0/fyR6Exx4q1KS5iISwu4MzS0wsciJrsPm05Syz0HaLzFkL3/yGGAQbFE4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=P2hw3NKa; arc=none smtp.client-ip=209.85.221.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="P2hw3NKa" Received: by mail-wr1-f49.google.com with SMTP id ffacd0b85a97d-33b40208735so387383f8f.3 for ; Mon, 05 Feb 2024 04:45:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137118; x=1707741918; 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=IzNCPI2uV4bVb56xzb5sANMJH8iS3z8IvBbUnLuAoXM=; b=P2hw3NKaq1enQGTKx8Xp+y30R59TcYUEwyrPNzmf60qNSrTMdh+Q6lgIARgMvxEwLn bI3DH/Zon1z4peFqvManSVrxvR/0N3XtUGQqw1zpcq8aei/VgBIcVXPa5jpEqrB5Gnex xpvB4CrtiI2ipHwPj3YqaVMO6AwtKH3LBlXY4DKeQRkUEdrP7vFJZa7RJlttrmtjHPLT YcGrIzBbpJJy7jDSa27omu69jSBuFZqjfgWY2aI1uWtkKtOStrVu0IKSttiwzFF+gUQw wBcQfd2nivcjWgpPe8JtbF/TOlX2yiBSJzWFq9mgxzzU1XbpALTgG8MtsFP9NZOLLV/r ghoA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137118; x=1707741918; 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=IzNCPI2uV4bVb56xzb5sANMJH8iS3z8IvBbUnLuAoXM=; b=YLqv7p+1yp41y7ERq3+912m7e9N0MtMCATtsYyeNxk2SCpWOt064OumK0wXReTy6Xq jyjHrlBqXGeBLU0dIPv8+EEALBwxc/H2A7Uh2n2N4F76wnvMZiCN/k2Tizum3IBWCKaT MUukHdte4Y0MNtFzTqDgXE1Pbnk70Pjp9WOv6b+ndWflBxrP9n/dsUbbxiHeWkzzedf1 mbzLuv0V1nA/NFa+nVIF2Xp9Dpty4/9RdrSzQo3TsLzh6vlo1zUy5wpVCiSrjTP847s1 jz+ZpwmR/oxC0thjz8D5nnScQBTT+q+gEgYWWT9T+Qti3cQGXNP6afIC+yoVQ/lIP1KM 8imA== X-Gm-Message-State: AOJu0YywOcyFQoo6oXv++fmggm33OAxY2/fjy2+ox4I4Vp4iTIN6iuyV ZwkJbgbcGoDwFvXX/3RbmQiEXAvkRCPZt1q9vn+Mox2+WD+RN2BhYn+t3a/q+Io= X-Google-Smtp-Source: AGHT+IFm8XMhSyOEj6JXeYBZfyH+577pYvFMCZlW+Kw7nOs1uHReXIMhb9GkUoJmry5cYkJROtgeKA== X-Received: by 2002:a5d:6481:0:b0:33b:1b0b:9354 with SMTP id o1-20020a5d6481000000b0033b1b0b9354mr8296412wri.51.1707137118681; Mon, 05 Feb 2024 04:45:18 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCWMNK1VDiEGqIAVNlJNMn+ZqV2UzxR+ZQy6PWi6/43efDeJOBNTObVEo1aWIqyi9Q2D3zrFK2uBuiC+kjoOMlWV8H6hFlFvBP6dnJmmkdiaojv1Ms9KR4sIp9xVR1Jg3+EpVR5ZulJUzrHeGoPBoPJQzlc7APQSdiPTy+WS1EkrHwkhLHmvUcasJMnakugFnt5ecVtBolqGBLuzMBIrmNxK91bzMWhX6CHRFyendF7RIEtH12rlYrgowJnLxYD955Pe2G6tzj2wH9FPT/BmD9dBD67Liy4u9JwFRfL/nDdHA7rxOgDtNzg0T7FS+/JTv6LoxCmYqSZm3BkxEapuwlE+CA+5tB87be+Av+GYBR+jWVinHLYtyL2NqyAZ0BvfCVa4FiihxgeVdQpPS3UZjjevD3B9mrOqL6t/A3nzgl0NjJwozlkShAjyHyLyZtc0qwrObZTSJ7LEUsejK5PVghUWfP3q6+6IuJfkCHfl7XUZAzypgZKwbUQ/zKuaUw== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:18 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 02/16] spi: s3c64xx: explicitly include Date: Mon, 5 Feb 2024 12:44:59 +0000 Message-ID: <20240205124513.447875-3-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 The driver uses GENMASK() but does not include . It is good practice to directly include all headers used, it avoids implicit dependencies and spurious breakage if someone rearranges headers and causes the implicit include to vanish. Include the missing header. Fixes: 1224e29572f6 ("spi: s3c64xx: Fix large transfers with DMA") Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index c1cbc4780a3b..2b5bb7604526 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -3,6 +3,7 @@ // Copyright (c) 2009 Samsung Electronics Co., Ltd. // Jaswinder Singh +#include #include #include #include From patchwork Mon Feb 5 12:45:00 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770293 Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com [209.85.221.50]) (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 3B5B41C29E for ; Mon, 5 Feb 2024 12:45:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.50 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137123; cv=none; b=uGlhRiI7pFSPlc3EM7X9wUm9jOtViHULfI63IRj6MP/sNySMXuQ9XfguEj08v+MPubfPDirYNjcpB4WH7tbHfPcCh7isokT88tx9s4MitZ49VQBscg6cO2GlaaxgTTvs4moiAtq6BCOs/SRSuQgabrPISQ3q2JGmp2Z2lEDQpV4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137123; c=relaxed/simple; bh=Z4Ew4nyDpzzGo1pM+lRVxGZLGFkSY7f2fYJqWCwnhYw=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=tH2QhyEBtNEEQy9uKgPqjyRa+UoN4+8wPHV+LeGKKtwxcbdNTEXwpW9TcsDTX//LRi3KzrkOIzGt8gd5KTud/BO0joaP3URr7oXJ+X6caxGUbNbFPBC9LqPDsFfJvUt0hZdYTcZu4Xw0OAXuER/n0vQMQrqMedl0J14fuHNoxgs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=S/ec5aA6; arc=none smtp.client-ip=209.85.221.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="S/ec5aA6" Received: by mail-wr1-f50.google.com with SMTP id ffacd0b85a97d-33b1d7f736bso2242151f8f.3 for ; Mon, 05 Feb 2024 04:45:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137119; x=1707741919; 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=W0iJZWpnXVMwkvXpPgSJew7EEo1nTNBnfpPHvIQNpUQ=; b=S/ec5aA6xqbeO1ETXeGMa00Wm505ZPWRGAPg52nwg7JZOmu+piZT83yVfeNev9Q71K bJ3wzhL/M3xn1sbrlmz/sDd9Q9PuRKplPTYuts2WVE+zo+bs9+OoMAv7y+2MozG3Wnxw VIHz7AN2NYDfqArq+kOTd1bOC8VvP5QkWMeQkDGSfPNCKZjrVFR1PwxCjBSZrfh9apiZ qvkIN+3nW631VEgCgsHHHZRWStCIToQgGNEC7qX0z/WkZdiwkWbmMFLoN13DBx3KAjjx pQawH0EWQ7X1VHZV4YttzkP99ewrsRT8AbUVhoCRyJdyQI/2hBFsv7A7d+r3jgcZ7Rjc 3seQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137119; x=1707741919; 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=W0iJZWpnXVMwkvXpPgSJew7EEo1nTNBnfpPHvIQNpUQ=; b=JBw4NJ0bk/bR4ccvWVhY3HaiM52p70ozI/5GravBRSERUm1gYxIyUIa7FB3+lzNBZC gR8mE88L34OJ8oCFIh3ul99A0YEgvCKEnIVvTFQNgJYAW8FwTh4t0vbROHsb0llTWrCE D1sXYUga0cA19c7ONx3eZ2btVWP3xQkO5B0fWf1jmSwreo+lhasXKjPlFGs0zwUAM0Gr dlzTdz9W4HWCLlg5dgtwRMysUu1HJC+IZhZUSk35ipNJL/esjne51mSyteaeAvqbQ/Ve k2SNp8T+AUPa4Xbz5elPPw1J+jksPcG8uTsPDIgDnjMhPEdqzaSaj6xwDVJ5i3kgAS+3 FlBw== X-Gm-Message-State: AOJu0Yx6CfUds04KUlSLKleC2v0xj1E6wK5ujNAm3gw+rOPuMSZm7xKJ fBFITDrI6KnBBEfTJC774wlJ2MW4anqxr2eavyuDM0OTyjArIW/oXGgQ3zsluNw= X-Google-Smtp-Source: AGHT+IEUTeDGMe9y9Io7d7vPFXq0/9oe6SH6ovhiw0963u3mRGK3Ub0ZC51fMHi6OyYN0hVu+gFbCg== X-Received: by 2002:a5d:5889:0:b0:33b:421d:bc01 with SMTP id n9-20020a5d5889000000b0033b421dbc01mr937267wrf.69.1707137119533; Mon, 05 Feb 2024 04:45:19 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCUahAXSvTsGA1585DKwqXFbQPhNA509hGouEFV78sopzS6Q+jluFeON2uLS/6ymTrU4IdZf56owEpKf/7Xq5dTT2fQTav0F9l/XLuL2m55hmDV1Bo/H4owLu/xUAiXgKIHz3Sy+4cAr4wAKB4ie1RWdUAQC+Y6eTIluyUepqtaPTR5Ip6RuWjdCy5jzQSzEfHOIPPAOOal1XQzCPXaJbtH9N5geE7MB3mjL0MtAL8bNebGI6+HzhEFrAR9+IxbPlAGf78worWYfixaftWPQ+YUogMJy92aAqgos1bmCRmWeyCLrlcsoqr+J9zD62Z1fhET61waZ4kgPlJxq5c8Bl/6PlfsLSDSFnE85zeKOqCrlSbcUN+ztFYZOfid4qeWX9oW6jHVdO0AXMpEFlm/jmiU92IhIw/cwRAB5UXAa/SHFVGDfusu2ZEDM6/75bBZDG0js0t5focKja7CPw+6gyZP5TCdxUf0xszz7mnWypT5jC6PosY5XchFNLKmlUg== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:18 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 03/16] spi: s3c64xx: avoid possible negative array index Date: Mon, 5 Feb 2024 12:45:00 +0000 Message-ID: <20240205124513.447875-4-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 The platform id is used as an index into the fifo_lvl_mask array. Platforms can come with a negative device ID, PLATFORM_DEVID_NONE (-1), thus we risked a negative array index. Catch such cases and fail to probe. Fixes: 2b90807549e5 ("spi: s3c64xx: add device tree support") Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 2b5bb7604526..c3176a510643 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -1189,6 +1189,9 @@ static int s3c64xx_spi_probe(struct platform_device *pdev) "Failed to get alias id\n"); sdd->port_id = ret; } else { + if (pdev->id < 0) + return dev_err_probe(&pdev->dev, -EINVAL, + "Negative platform ID is not allowed\n"); sdd->port_id = pdev->id; } From patchwork Mon Feb 5 12:45:01 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770554 Received: from mail-wr1-f51.google.com (mail-wr1-f51.google.com [209.85.221.51]) (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 1BA101BDC8 for ; Mon, 5 Feb 2024 12:45:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.51 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137124; cv=none; b=oPtZnnNF5gNMZm6ZgOlV5qIo/4yep0rZI3jjs+LD8j/WuJapt7YQ44cB76RJsTVnbajvy+ptb101Ub3jX8jIGIK32PKfM31t797/VeH6nI/EN+L3TGmxujmSiNEp/waVEULzFNW5cgepIXfkWIlOomQq/r1dCrMjSOsh9LWHEtg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137124; c=relaxed/simple; bh=F124QJAevKWdFhGb5sj8HrO8muyAjVQUMric9Xoo0PQ=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=TpsO5JUk1GGwE34UBymt86e1kAyjkV/Hs3+ChQ+I9sLBN2N1jO+446PuIu5Lvyv3it/NbwZFyCE64ptn395yHu76wjTuuCv91Ylb7DmY7RJKuIMWqn+qsc+IFWS9MHF+TCmvMAqO41CnNd0Je9hKU6TJGPiI95WozdY479noHu8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=ytmQxFes; arc=none smtp.client-ip=209.85.221.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="ytmQxFes" Received: by mail-wr1-f51.google.com with SMTP id ffacd0b85a97d-3392b045e0aso2446887f8f.2 for ; Mon, 05 Feb 2024 04:45:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137120; x=1707741920; 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=eOBjoaorUabw6V0kVhecCBVM+DqJR5V0WfMbUMGzKiM=; b=ytmQxFes1ArYQxU0/WAEZsWB7bHZI+JEABZFpFeehELiXjFZ7O+380widLKzXGvCN1 wETkdeQnP++UbhJHoVYpz1ukzxR5f0BLpdGQZ1OaYolbrirexBCGp50q5up+HjOCLljT jLITSDjcWHXAa6SwKz6zeB23p8Io24BbY+69aDdJVW09pp2f360Kl9RwMANXd8wVVg0J O0SMmvvrAsNRZlR5bIWmYZRM1U3sKnyfqyMGGKnUI1vMHy+T++CBuLfSdL4O4u6mFSo/ Pd0XGxJ9B3BQ7SWi7Grw5LRKJYUD5JDIBHh+j4MQRN3kaCbWqDIxCooaM3EgL0hkriqB 8DQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137120; x=1707741920; 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=eOBjoaorUabw6V0kVhecCBVM+DqJR5V0WfMbUMGzKiM=; b=WSAaB88ztUFE3iFjDRa+R3tqtsjeKxZMr4pOu7Xit6IAMkQrlxxakRZycGxFq9X0QS OYXn6N8pelpvw0VHBycgcljozo9fd213x8+wDQ/fxu9Iyzvdw05LHw+Y7am7a9Sx6PEA y4bFwD4dMdS9mJItAK8d5pOLltlj1NqNWCdcZc5GizFpaBU/gkASVky9j+DMGyrwdCZa G3GKyWA1JmXq+Mp03HX0jT9XHOPuCEh4Yyatse85K8KvZNaUk8J7iC9fVCAaoiX71Dan a4bkfv9csjirk7W5smaXoK9x0rb9sD3IcoyD7afk8+SOVeZX4MGU0D+cWGCWbTkZAbuH XM0A== X-Gm-Message-State: AOJu0YzNtBOBWv7Mjue75SFR+pDcapbkzo8MQplA33mOdIcEEAgRAmHn 1V3VI+2esLEpWM9BtRoiuDZ/I3maP2irAMLZe3xPQyxdCQ/gOc0FKTNQWoeZdoE= X-Google-Smtp-Source: AGHT+IE/R//MpNPylh0UwnhF9YKZR3KGGY4fGA5i2/YHcwiL3Cuz8pM968aVwJ0sUeRb5fLUjg+zTw== X-Received: by 2002:a5d:64c8:0:b0:33b:3b96:87b4 with SMTP id f8-20020a5d64c8000000b0033b3b9687b4mr2800257wri.14.1707137120374; Mon, 05 Feb 2024 04:45:20 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCVMfIKOUFnj98diFmwBJtthJx6XEcrlECRzI+G2PUYmp9a0qQk6FHpzoZ9Ia24ALKuUN657wE98H7tOGJZHXUA8msOETP4O6LwvEYPkhKFL0nxyBUrL5e2O8PpjE8+a4M9P11ukmFcNBgXZEa5aWKSANDzieilHAieWiKlkvLrl13nCFPWQDtoDpKen60XHXzT8GvyRKD0vD//k+Qg1LxdRN+OAWLXIj1JfNpuN7SLfryV6uFyeKnFgV3lAGAtE909omOuHJ5ZKKnCxJ33RwVeCOHVP1+ZoaQqjUzQ/CMVw80T4NvSdqgiC2OQow6M6qnGiei69Mp7y7alVSVZkJ1ldjTF35HcXRcoCWooaacUQTyzUzMuFslAV2REvXdO+IicsZi5ls10DblwKzyoM1PGP0iWzrmPzgE0Bol6vhVkkb80eWfLhYsJwxLAt+xlvddzVmWCt7BqPk4BIU9IpSbhTdg1EU/O/4BVSuH2MpZeYc7sOZdT093oW1fodyg== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:19 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 04/16] spi: s3c64xx: fix typo, s/configuartion/configuration Date: Mon, 5 Feb 2024 12:45:01 +0000 Message-ID: <20240205124513.447875-5-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Fix typo, s/configuartion/configuration. Fixes: 6b8d1e4739f4 ("spi: spi-s3c64xx: Add missing entries for structs 's3c64xx_spi_dma_data' and 's3c64xx_spi_dma_data'") Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index c3176a510643..3df4906bba34 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -180,7 +180,7 @@ struct s3c64xx_spi_port_config { * @cur_speed: Current clock speed * @rx_dma: Local receive DMA data (e.g. chan and direction) * @tx_dma: Local transmit DMA data (e.g. chan and direction) - * @port_conf: Local SPI port configuartion data + * @port_conf: Local SPI port configuration data * @port_id: Port identification number */ struct s3c64xx_spi_driver_data { From patchwork Mon Feb 5 12:45:02 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770292 Received: from mail-wr1-f41.google.com (mail-wr1-f41.google.com [209.85.221.41]) (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 07AA31CAA0 for ; Mon, 5 Feb 2024 12:45:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.41 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137126; cv=none; b=hxIroiMX8cm7BYf6/vqHhUfBCQ8sAoKV6Iw7haoW066Yil0ZRnG1Dw3m5DLvqTEq2h3922hQwVq5itKjQIgJWsIrWitaozJuhxGddpQBerOwbXNZXpYuooUbUT2Z4uG8ZNi0h5V180grDpRQDpAOoayf2fftuxpb8+MW9cdf2TA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137126; c=relaxed/simple; bh=7nZy1kjX8oYl6BiD9WLVkh0bXeWbHcZfI/Pdmt/baMc=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=QTjBQ2VmzK7aIIQHzPYDAEJjvS5Fi2yF/kSbia7hOCqd5e+wTLEGbjXyekE52IfUYV/lJlggTaEfNPhlKKVddY6VTsIhAL9o5zL41LVeik9gblTYLu8w1ETm2Ej++PbowCPRWDr29YGUeTOBXr/qz9Sb3lafGZk4nsjp1xRy6XI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=NK2B4voH; arc=none smtp.client-ip=209.85.221.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="NK2B4voH" Received: by mail-wr1-f41.google.com with SMTP id ffacd0b85a97d-337cc8e72f5so3239472f8f.1 for ; Mon, 05 Feb 2024 04:45:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137121; x=1707741921; 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=K2PV+2xLiiEx0u7i0xiK8BO9Wv2wYApgzlDJ63/0dKw=; b=NK2B4voHJCQkkijaZydQ3dpPnAFlkz5rgTTBwrVcDBTF7oQHq7puYrMZg7f1eNERX7 C5IQ58TcvEQWAeP/tbEobKcyOfcX2wbvguR5ZVAbpHgKzftztwSfsW7XGZNFl0a/547K YIZoBRW2Xspm0vJ9B5YA0ul/pETSbEIS/zrC+nof9foT6YSuSXMey+7DK4DUIfVIsAOJ 0Og75bbd44YjNpMTKBNf6vAnZNERcNZHthmQCyv33zpP8sGAApQ6OR3cvy8tfI9LF8DP VmeB0Glgq5zQr926ilGaEtifCqP2iV00ZUyhn36jUHx8eAP6yqXg6JfCzDJdsb0NlaDQ ZRaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137121; x=1707741921; 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=K2PV+2xLiiEx0u7i0xiK8BO9Wv2wYApgzlDJ63/0dKw=; b=Qtl86t92EekkMGinEifMoGNKw8ab0OsYqxFd8wMHM/vxza8oZI2y2snkiSax8qY240 fZQ9oru93RtUalfhtTnF9BcO9bTJ++M8f76tCMykQw2G/cdUeBF2686xLNOxIxDzsNg6 7Hky3CUDBvQLLDNiuiN0vCAikj24H47/gU3wKCiNv0O+ZcUYrVNbZQ9oyBwHvSdfD5B2 EiuUstJZp2CT0etTA9XDoLzRD9KUdYltVC+iOakDBEM7MODyb7Sn8dVm78umcB0PshLd 1bAWYiYZ/SaQxGINn1MKZchYW5yKx5l+jHftql2KqoB1m5yuZoF0D0z4ZpEarYGEdRul pojA== X-Gm-Message-State: AOJu0YyewzmZvVfJ2sc+upE13CEap6mC/ClDtnNhc1uCxAKBvFhCm31y B5ZcHkNmOZcOXl+7ga3zxY5KR+nlwnrPyqGY2U8vZ9BYzKTQeVOkcWC/Z5sJx5w= X-Google-Smtp-Source: AGHT+IEuMR0ZRLWGw37NoH1Zqp3+O7Jprt6LM3gpDZR40q6RTfgnXr50yLqhP6tQPXGpkUFkUupYSg== X-Received: by 2002:a05:6000:118e:b0:33a:df1f:c18d with SMTP id g14-20020a056000118e00b0033adf1fc18dmr8072680wrx.50.1707137121436; Mon, 05 Feb 2024 04:45:21 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCVGMfma0EN1z5FoQBginlFOPQ514vwJSuFrlUAxZpiJfgYEsovYbba6ktClwtxo6O8Ti9yHyvJrVMfsJzaqzlZ493BEMH8JCmzu96BVZAAEDexcHp4v3CTlBAQiz4HAPhrwfH8TNmt2RQRAIv+Mg4dmtZr6oDHNmrA79YVU/as54moz0bxiwlwaZ/zhga53Q/IcWvZkeSfsMsvcVhKBkrvJNNSzASvTE5rWWbjI4nEUpbKS5ySwnc8l+NGYSG5f5FHWMs+6/rt+sPPfP73Yuieaiv2z06VfdogYi33P1Y5AGos7EE7/CmZ1T+xkkXA2K1AzGCXXLG1IFH1qfN79h8eMs672K55Pcb5i6+JmJ6aR/Ww+JRIcnSgrRWVVwGua4NUxpUUpvo0Z4nAwEqR1gVkvTjTSqLqI8ZxzOskDbc0pVEXDlY8TCJMPmJfmTCyE8S7FJ3WzPg7uMO5HjZ3okLEpjvxuK76r7aQCMCatSIJCkzuYVH8eHtUZltL66g== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:20 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 05/16] spi: s3c64xx: sort headers alphabetically Date: Mon, 5 Feb 2024 12:45:02 +0000 Message-ID: <20240205124513.447875-6-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Sorting headers alphabetically helps locating duplicates, and makes it easier to figure out where to insert new headers. Reviewed-by: Andi Shyti Signed-off-by: Tudor Ambarus Reviewed-by: Peter Griffin --- drivers/spi/spi-s3c64xx.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 3df4906bba34..ccb700312d64 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -4,20 +4,19 @@ // Jaswinder Singh #include -#include -#include -#include -#include #include +#include #include #include +#include +#include #include +#include +#include +#include #include #include #include -#include - -#include #define MAX_SPI_PORTS 12 #define S3C64XX_SPI_QUIRK_CS_AUTO (1 << 1) From patchwork Mon Feb 5 12:45:03 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770553 Received: from mail-wr1-f51.google.com (mail-wr1-f51.google.com [209.85.221.51]) (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 383E51C6BE for ; Mon, 5 Feb 2024 12:45:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.51 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137126; cv=none; b=gptgn0WIwmpz51j+XnM49/fIOJfc3j32tVqs9IOnoguwEb3tgsYCW4XPdFu1T8/QjLiLmxPvflkKSVRe/+WJMIb0CMtdBjsSenp3cCu5Mu8U3VeIvHA8Tp9Mbn9RFYCxstR52dLoWkCDTU9+eAZEZ61g5Shxqa133++5a74BAI4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137126; c=relaxed/simple; bh=uN4pmSgYbRXI2jvqo6UzvAcRTx54tWVkaWx0En1evXA=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=O2ggiS2HX+TMh2mqiqz6xodW5y/PcgDVSyqXHNJyDbCWJmqdoJpb7uJ0QUBFNUO16dmNloCiqz7N88oMWCxZY0OeDzja3wxSNDyx/xf8JYELF986/6rNz3AQlPjuPsMqU9TqgTYVziPGPzFNFV7SDpIy6Uz7SaiQIPud/nNlKnU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=ZaqNWtV+; arc=none smtp.client-ip=209.85.221.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="ZaqNWtV+" Received: by mail-wr1-f51.google.com with SMTP id ffacd0b85a97d-33b2960ff60so1123470f8f.1 for ; Mon, 05 Feb 2024 04:45:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137122; x=1707741922; 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=dR8F8TtLujJzML+VHbYFd966gNYU8tLxVBTCD/Qpmho=; b=ZaqNWtV+PIeH/DoZrTyOqgIBIeqcDVuC4BIb2sMNv0aCfubHXOnvNnQPgv7zN/XlTc isjlKtovaCOc1y7IvXjFdhlmFML8ixdb8KpW86oNP6+brY+OSeclBO1kqV3DuLOMH4kB TKazF5fvChRPJnO12Ut2Mijz+zgfKjyDC2WNLKIf/jXDppc13MVHIRDy/+lhngDBNjU8 XVTpPhk7VPK/8z2S81xA1z9BfBBsZA28clzNko+zQFBL4+xOlSrXvZV7lkVMekLX+TVd x9WSTzRZtjjOG9RPYptKMyW36ZMnfzIEEuhZedD3B4VqJLKsEtN2c2KZBbSHsak1XNVW nU2w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137122; x=1707741922; 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=dR8F8TtLujJzML+VHbYFd966gNYU8tLxVBTCD/Qpmho=; b=kBUSEOGeaEwESpjH5hYFEYKROhe4ZxTFLnXR0pERgZvyjSJ+OPry3XBg3uko62jG2q g/J7AvrIsHrOKMWURdCRX+UNTBX/xk3qPoHvdxWexH+zo0X72oHb/6IMpD/ULve210qQ xGvHo4Y2+ssHNAaSmbmVy5MqYZ/9QxTar2230FE9dcqFrOcfMdzUECRl/sxYcZ7JDuly cxqcfpDhAHOdlqcP4egpBYiWx91V+Dm7g4WLn5Jy8iSQkHIiW4c077R5Tl9CfYgpBUWI NJYmBCpajLeDt+8o9KWi+ls8Bo1s5iQYpYimCcaJQZ3AroEucjlpuu5HpNaRRYyZlYiO mk+g== X-Gm-Message-State: AOJu0Ywdj4zC7DgdH2FU+yEr9RFDSDtalpxsiNBP8/uzwj7wuIYZCr+I URHiyChMpVDpd1EaMED3ZY8nPftb+M8Z1HfJOiqF40B+8qWOe8KC1v2sC/8ZqA8= X-Google-Smtp-Source: AGHT+IHCuUmi+aZgBfk65jmiz0AIwSuZ9vOXcT90pjJQzz+4Bn7QZ2XAsQmQC/0j7e9WxwoFjwSkYg== X-Received: by 2002:a5d:400c:0:b0:33a:ebf1:2bf9 with SMTP id n12-20020a5d400c000000b0033aebf12bf9mr3498784wrp.21.1707137122511; Mon, 05 Feb 2024 04:45:22 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCXl4yO1d8qcT/Zxvb0lobqGRNH7mNE0zJaKCteLlrfEU+JyL5wm+nZfgc3HDif717jZhnK8AwmpbghCtGct+2Q4SODKEIqEnCEHt/sPiym8+bPgxcAfnqA02Ugtre04fhpiMpg0MNX1JE1IVOgtRrWroBjq7Qj5MjMpKpu5CcWwA592/JgYX3AAxwL9HXrQ/3vuohqfTyORMqCNSlS0EaxsQ0ciJKjXwAhR/1GhvyYKmmlVixm8B+MAFM43NEvIKPIHWZmO41pvSnas7pfGoocPlN2I1qUWwExsUfHAvRR3ae9tSP2+VDIAMWLD8UycDNRRe+qlsnzfMctaHdmcWLQzk+hkQuyveQHQiTQyRRNIXNFSquM7JhAeKRy5pezKZ5tuTkkvn8PAUinD4LHmMOmyuqwkknpYtNubu5rdUBAV7N3zU8BHQ6rn9wvXbctFHxNjvS3V2tmvud97IGGFNigC4qmZmRx+bda4Rdt3ZZrAKj0K3XNHhA3/liOBog== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:21 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 06/16] spi: s3c64xx: remove unneeded (void *) casts in of_match_table Date: Mon, 5 Feb 2024 12:45:03 +0000 Message-ID: <20240205124513.447875-7-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 of_device_id::data is an opaque pointer. No explicit cast is needed. Remove unneeded (void *) casts in of_match_table. Reviewed-by: Andi Shyti Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index ccb700312d64..807270ec3c8a 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -1512,31 +1512,31 @@ static const struct platform_device_id s3c64xx_spi_driver_ids[] = { static const struct of_device_id s3c64xx_spi_dt_match[] = { { .compatible = "samsung,s3c2443-spi", - .data = (void *)&s3c2443_spi_port_config, + .data = &s3c2443_spi_port_config, }, { .compatible = "samsung,s3c6410-spi", - .data = (void *)&s3c6410_spi_port_config, + .data = &s3c6410_spi_port_config, }, { .compatible = "samsung,s5pv210-spi", - .data = (void *)&s5pv210_spi_port_config, + .data = &s5pv210_spi_port_config, }, { .compatible = "samsung,exynos4210-spi", - .data = (void *)&exynos4_spi_port_config, + .data = &exynos4_spi_port_config, }, { .compatible = "samsung,exynos7-spi", - .data = (void *)&exynos7_spi_port_config, + .data = &exynos7_spi_port_config, }, { .compatible = "samsung,exynos5433-spi", - .data = (void *)&exynos5433_spi_port_config, + .data = &exynos5433_spi_port_config, }, { .compatible = "samsung,exynos850-spi", - .data = (void *)&exynos850_spi_port_config, + .data = &exynos850_spi_port_config, }, { .compatible = "samsung,exynosautov9-spi", - .data = (void *)&exynosautov9_spi_port_config, + .data = &exynosautov9_spi_port_config, }, { .compatible = "tesla,fsd-spi", - .data = (void *)&fsd_spi_port_config, + .data = &fsd_spi_port_config, }, { }, }; From patchwork Mon Feb 5 12:45:04 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770291 Received: from mail-wr1-f51.google.com (mail-wr1-f51.google.com [209.85.221.51]) (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 17D7A210FF for ; Mon, 5 Feb 2024 12:45:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.51 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137126; cv=none; b=cYOvV00RAecfpe2qDWsLjR2xzd6U1jQhCP3NaPT4ynhmb8SjzN3efB9MAQtkNq1y+9hBh2K0U7SdzHE4ah83XvCnbEXHfrP/W6oIslHqeWEL4XlBAFSfUnMfpFzUQdfEdD2OfLKVgquW8hlitfQXdQNkeZj3p5+Dk00BmO5WHaY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137126; c=relaxed/simple; bh=0FQexx2CtUCxavZKSr/J2p/ydSe/rTCGVQ4ypBgxYlA=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=PM7T8to4pG7wd6HVmlP3/KOG1t+Cxqhp/8/tw5benLmj2c/ysfxZfR4hHOOhJqUUBsFLm5yqStElbCcdx+CeAQXWb3cvUS9sNy98GPbBgwxOwra7HD80YC0VOxJz1Iz3e9GzG4n3d3IbvUVTtxaxz3KzmBr3TMMQYFUMo2hFzmY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=ooErDcYy; arc=none smtp.client-ip=209.85.221.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="ooErDcYy" Received: by mail-wr1-f51.google.com with SMTP id ffacd0b85a97d-33b406e16d4so376443f8f.3 for ; Mon, 05 Feb 2024 04:45:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137123; x=1707741923; 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=6qx5Z9yzI7/GsBIXv5d4Hndyborn/ItKWNP+WpKBQHQ=; b=ooErDcYyS+T3P04nrNz40IadKc817CYzIWkaaXXvNQmrTYfvw/5Ow9s+d+ot24ADHo xq8xWUwWUoLhfoTUbk2uVITfVeLi3RUNphnBKNOMUtRuTzS2iDzZWbY/HGvla8V3FCco vnBY6oXMzKkNMkFbtfxzVjZaJuo3MnCdHaeovS2f5tDRZCewH2gGCLNT7abyPVnVRy25 sMJvANx+NeG8gEFopXB8pn/QKkNLQlV91NLY7iMmWbcGSfhQVhotQgTnDVrPgb8R6BlY ovh2Emx1ifW1wutsi78AvFEqzoRw+RoGfiwZ+K3pXxW71Oc0dsABBlzFYP5leYJ7KvUQ g+jw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137123; x=1707741923; 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=6qx5Z9yzI7/GsBIXv5d4Hndyborn/ItKWNP+WpKBQHQ=; b=ZiJe8FE27NbGILKJJlh1IP6d+0hy7aaKNMPc8NRNvj+9GdlEHiO5O9C0/R43k6FkKz 5xTITE146n1maOibK33ssmFHWTUHzzAyCN3lSzDySfFXtjP9ghGA9IPFHj0XmZqUmhJV 3qqUhK8h8dhP32R18RtBu3SwYfkLWZ/Zxm0flvaL0QyyD7PMcjCfOJO8Hiwj/dKiwBWZ RCpkTNpdZOn8B8ruFfzdFfK8K8BfzLI0wCXSukEgqwdDhK/Gx7xHFXRpDQTvLw9UMizR oM0riAw2nAin6UO9Vk4h9VJGbEiy9StaKOPTXH913MpuSqr0t6u9/KYAD72xGIf+uKNg yDbg== X-Gm-Message-State: AOJu0YzQgI1taQBTtvHD4Ir0zWNogU2sSwwIlM1Jg59FFE9OTCB23KgR xdhJejk2jpnwHB/SN3JEwxuzfCnSLxXDWb+mhMKtyCZMUuxeiY8AftjheWwS+nk= X-Google-Smtp-Source: AGHT+IENb5/+ooWzL3wKqSyw6CoPegzi2HvBdBv0v42N94vmcjqi0ERz9OUD0oC6LoHzUuwF08Ctew== X-Received: by 2002:adf:eb87:0:b0:33a:e76e:8b5c with SMTP id t7-20020adfeb87000000b0033ae76e8b5cmr8704510wrn.33.1707137123500; Mon, 05 Feb 2024 04:45:23 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCXNyTz4l/uM3TNton705PQDnlbNrHzvQdIFoejDWZAaXz/PhUGIrVzx3X3u8Z6k7b5yAy2ikEcTLKhvJ2bwsyKAb+V6tWslcNkzaah0b0f4QIBD8FuFWARi8zqXG4RjvAltC+1j8ps0uo4Y3rDq0U4Bx9vKyPAcQolk9o4EmqMQgcyNBFBu8ThEi2IMmvcoc0oXr2zdvuezf9naLI2GxY1uH0GI44nB4TTtATOB1yKx0kLN3bcg5FTgG1nXHc+OgzVpVcgm/jLpsiE4oM1SkYfN2CRLpC+NoBUWFGi/bGYnQhiZ3BpIWrlj5QHb1LTZnomSGYmBoUaxklUvjmCPC/dEXbzUwFbLiYExkOHKyR2MtnHxHC2RQuToh1glcAKITUvDwzY0zO6NZn80VxOIDoj9pljSJ0VYjmuPUI3Eb+Tbu487QVGZDBOg4jzk5GQgFeycEXIpzsWBaSrt9kFGzfhR06VFEqPItaiR5iLwQLUAk2+9kqOmaTcto1lqiA== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:22 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 07/16] spi: s3c64xx: remove else after return Date: Mon, 5 Feb 2024 12:45:04 +0000 Message-ID: <20240205124513.447875-8-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Else case is not needed after a return, remove it. Reviewed-by: Andi Shyti Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 807270ec3c8a..3139a703f942 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -407,12 +407,10 @@ static bool s3c64xx_spi_can_dma(struct spi_controller *host, { struct s3c64xx_spi_driver_data *sdd = spi_controller_get_devdata(host); - if (sdd->rx_dma.ch && sdd->tx_dma.ch) { + if (sdd->rx_dma.ch && sdd->tx_dma.ch) return xfer->len > FIFO_DEPTH(sdd); - } else { - return false; - } + return false; } static int s3c64xx_enable_datapath(struct s3c64xx_spi_driver_data *sdd, From patchwork Mon Feb 5 12:45:05 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770552 Received: from mail-wr1-f52.google.com (mail-wr1-f52.google.com [209.85.221.52]) (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 B6B0228DDB for ; Mon, 5 Feb 2024 12:45:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137128; cv=none; b=mu30cloyPIa4Rsdj5LlK+OfiMVy2ztATEDypoQRbXpOR3GBNO27MKyTREYtk4AdIFkznIq/b3NENDGqW1fMffIooK+GQ96sGuuOh16J4Kd77jzCuMkM56cjXMz/Kqdge1wC5rMjyK5VLb7oTtTpqV0kLLcy1uh2MQOTsrp/9MiY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137128; c=relaxed/simple; bh=fsH83Gl3RkkVFWG0rTvkjArWvOWiPFJ8T6oyUGVHsL4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Cxd0oZ9FPfer+Iyq6e2uposxnjzNFs+c6azJfbg61eWeOatDgvhOss2BQtHF1xlRFyK6cjksNgx8sdcthd2xNXkkFEF6lyxJD1CP+cAhVREq8qWnXBSJ4+VM5xDBhFbeicEJ19/yPS8psnF/SD5HxcP+ezxvC/t2qJXzJyPFF0c= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=p+gR0kAe; arc=none smtp.client-ip=209.85.221.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="p+gR0kAe" Received: by mail-wr1-f52.google.com with SMTP id ffacd0b85a97d-3392b12dd21so2415081f8f.0 for ; Mon, 05 Feb 2024 04:45:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137125; x=1707741925; 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=Hl6pdkbEEgoE8D882wXKu1rMaFEwskiVorsz3uU2gaI=; b=p+gR0kAeErxWwhrUYOmh2bnwXrC+ip6xOjV5lPQghgCy8QgfIxbODhou7fNgqbYzu5 7dd9+8rmeiJKRO5DzLAHkO+z/2/oKKYIRxSIuC2SCJ2jTsKfIfmQ6jdTeMude2m4WmsI Ak29rglFeQtGxumTvhMA91s+25tTALzxMWREzHlT8xvxZvJwCWmwL3F18QNB/v7fqeFR 0ju4nwRyOWtV5qwWYAMLf5ukyEz7q+arR369UjLLecHZdh+y5P6q+KiylmsduFhVpnmM FYjz5KJDmeG6FNSbkyWRXQJaOBA1orvZFYO/BGooExTl3niF76Nk594Ec2ie7tPN1bgY o4Fg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137125; x=1707741925; 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=Hl6pdkbEEgoE8D882wXKu1rMaFEwskiVorsz3uU2gaI=; b=WqQuikRMXRFxYP5bNRpLgIA8KpTNdxFEVH3hwfxa2IoRjpAEe3hzT/bUFqmnQxiSuW utQ6Go05DhcE5zUxxzc57byzz+6kWygDCjGyAXJO4s1sN8TshXBZW08xN6pHi2gZx8Wi IzKAA8Y81DvBBWz1WsMmuivvU0ubnJBrPQ8k2Qt8fsuTDXv97Zzt7+sU9qe6giqWQNOX m/PxkTeapfJhUOv7W6nrwbacdHqVFrOms8h+xL2/Jec09Kde62LzQavgmIntjQwOS+0X ITLX/UHaS0bhXEXJVPxz1MxuDgh3U145tD7y5pzmxZmVjlaioIpfU8y8K2Rn6XA3S3wk nHdQ== X-Gm-Message-State: AOJu0YzeElmUTD8kmjDndWCDouO+ahi0kS23XkC0yV1Fuolwm1R0KR5/ xQB6tyQesruQSMefX3GD2himaD5FGVfPnXiRMD/iOwbi2wbAYfABmE53NPfyyBE= X-Google-Smtp-Source: AGHT+IEDe7EYwBHsgvEhHYw624nCPgXWvF+fc6geJZnawHKlv5pvLV7pnjnL7oVE2MzVyCIouzoc7A== X-Received: by 2002:adf:ee8c:0:b0:33b:376d:6263 with SMTP id b12-20020adfee8c000000b0033b376d6263mr2789597wro.60.1707137125019; Mon, 05 Feb 2024 04:45:25 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCVw4l7u+dPerpX2iIeIYeJpmDSZSVp/7atJ5rF2+W2qzeYzQ5703ZVXHX6x29RJ1tujigETMOU2yc6xB9Ao+8shHtUAdq0s5rzjd/tzE30Yb9S+frHisBdUz6J4HALhnWuytIGcGMaBb67tahDz/PicKwT47gy77pRuZdTEiNuaaUh5KBKMkZg6XI6XPftRYGE+Dvq9NCuIe+EVqKDF67OqHcGj1u4R70DsCpl1BYgbGaztewDF/cS49zmboaojgEHV0ULVsNyH63Bqr0FuFKIm3pVNFx/zkoaXqPRzEhGIE5hr51KE5BPnMbiO/yl7I/8iQ0y8Fvq+z5gMree7F2h4DSk6ZzMwscytFapnDl/E7Q1tG+d/k8YjshGcKs8xVlQN2i6z8q9RsIfyLpNLqlUCgXKTk7KD+GmpqvLYS2Xn7ZUZqjs+BOfnbyR6ryCAE/FYwoEr9+bokYIz5jAsqbpz9nqhiL/n22QPd50RgSvdv+LbvnYht5g7n2vgIw== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:23 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 08/16] spi: s3c64xx: move common code outside if else Date: Mon, 5 Feb 2024 12:45:05 +0000 Message-ID: <20240205124513.447875-9-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Move common code outside if else to avoid code duplication. Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 3139a703f942..fcc1f16d3ad1 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -291,20 +291,18 @@ static int prepare_dma(struct s3c64xx_spi_dma_data *dma, if (dma->direction == DMA_DEV_TO_MEM) { sdd = container_of((void *)dma, struct s3c64xx_spi_driver_data, rx_dma); - config.direction = dma->direction; config.src_addr = sdd->sfr_start + S3C64XX_SPI_RX_DATA; config.src_addr_width = sdd->cur_bpw / 8; config.src_maxburst = 1; - dmaengine_slave_config(dma->ch, &config); } else { sdd = container_of((void *)dma, struct s3c64xx_spi_driver_data, tx_dma); - config.direction = dma->direction; config.dst_addr = sdd->sfr_start + S3C64XX_SPI_TX_DATA; config.dst_addr_width = sdd->cur_bpw / 8; config.dst_maxburst = 1; - dmaengine_slave_config(dma->ch, &config); } + config.direction = dma->direction; + dmaengine_slave_config(dma->ch, &config); desc = dmaengine_prep_slave_sg(dma->ch, sgt->sgl, sgt->nents, dma->direction, DMA_PREP_INTERRUPT); From patchwork Mon Feb 5 12:45:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770290 Received: from mail-wm1-f51.google.com (mail-wm1-f51.google.com [209.85.128.51]) (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 97B752C1A8 for ; Mon, 5 Feb 2024 12:45:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.51 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137129; cv=none; b=tdLM1+nJysLBbIfGmddbIdQcKnpro89DPXGYc0BRUs0ZZmV8RVeTkDcD/8RBaddyhTGKQsXJNUskph8lddJ4NwmA5z7CLAnLaHmwfOOYceArcQ3bnECmvRhDPPSVN5TQFHNYo/UH5WyjHJVTUmj1QIJFo28bw9rsCyCgmVV8bf4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137129; c=relaxed/simple; bh=SPrCOsQxxjla/vMCkgij7H48llhpPtwGBfHWI5X5uAY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=lsK+/92ma43DFFxqqmco4emzFVhe8Nqx4qJLAw8xVEY0skH16Q38foMYJFzNoqwqPMbl2y4VKaE2V2+NAtNVpSxpMztonjpiGPe/oUjl8iaDiN01wrR1/KKcSETCcs78Q+fP5pmVthIu33cIlGOsAriCydUsh8C8KlYaIZzYlrQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=ZfGlqtpx; arc=none smtp.client-ip=209.85.128.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="ZfGlqtpx" Received: by mail-wm1-f51.google.com with SMTP id 5b1f17b1804b1-40ef64d8955so39931365e9.3 for ; Mon, 05 Feb 2024 04:45:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137126; x=1707741926; 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=ndgta4k+G5qoRIAYZxQhEjhM69MpnMv+KGVE1CZejWY=; b=ZfGlqtpxLtJd0qx/y5lf5tCx1gxaMalot3xUWWAqgaA5SJo1YxByJ/U26RgrU2F3Zh whyfPgzFxB5GIRvLzhRsKcIrwLGz0966XxRjnZDrTIfbjjVd52JmnCKTjJgJcEhByo+w P9+AL7saEACZxC7nc2qtxBp7z0kcI9yXCkXY9LmykgCCVA/TirPmT7/0qe0rYL1O9/iF RFaldB0ZsUYEjhPnsV4KxQXZrFiCHXxBO8GrNJpxbcurP1w8l+8nfWBqqPamytIaOreH qK5pebaMJcG/iday4cloGEEMY36SjcwVL9zrF/A8UHg8JhUEdg+K6UgQ/DL0jqG7Qqmk 3eTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137126; x=1707741926; 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=ndgta4k+G5qoRIAYZxQhEjhM69MpnMv+KGVE1CZejWY=; b=lHspNL4pEqwtrCAmoNzU15L06BDsAtUpaobwpxJLSJVZjjUQBrFeO5LqOrZRKQaUlF 1nqnA4XcUut8j21/G2Bxc85CDBHo6AQT2byqskN1+ZgRKbqvy2tesMk2Ebv7eF6cKUco v0MOMi0GA8fucayf+gOOa/PKfp1OIomxVjmhgMboiZMakUxqtCIJucW1ZNxnGu5eEkIl PvapSXbLW0c2n8VqPKAiuBC7DdwIuIngdMizmiWEGKWkKBQbA6RSMBFQIdcWBd9uL/50 z0pxp1AISC8Fe1yb0VYVGiblpXwDDEBFn9DmL7cm5m41Es4r7+MUss6nfDWrDA1P+J2h PiVg== X-Gm-Message-State: AOJu0YzgQL/0Xp6p3S9zB78+xXSznrRXF9qgkl89GDrknw4xQNyTYOS9 plCK55RHM+L4e0iz4THpU2kIAXJTyi+DiReJU3j9V5LqNDCN1IF+CRer76QrQL0= X-Google-Smtp-Source: AGHT+IFfo3cQQL9/HnpiLvwbqAwEr44KXp0C33JXwRj/iVJj6s2NcvsGUE72XOVRphi8QHeffBQCgg== X-Received: by 2002:a5d:42c5:0:b0:33b:2464:9d8f with SMTP id t5-20020a5d42c5000000b0033b24649d8fmr5556272wrr.58.1707137125934; Mon, 05 Feb 2024 04:45:25 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCX4JJNaf1yBR7JlAEEqs/vM1bpQHP5WCL3yheh+1Kk+jWGt1qmnjBQBaHyqiZZQd+WQry3owsObYdswipM/LUbjc4iKp+vCyWMu0+PIKN4x5dzcFLRn9rPoqXXdHAOzymMl/Hw5G6vuBwa3A47LFDQ6m4ja1R8p0RkwUW8INsVUpTDkDR9RIGLQvZOabOu9aLo3xeCQnh0ueBq9FZeUpz0utDS2DCj35GvobxhpwJynTO61ixqSBBVNmXKMduQdzModeSLGlpXGmpoucJ/zNDcIhTSlcBBc1oDAI6Lts550pcPIy+IjfeYN3PFOGRxW/n5it04PIzIwudWyr731/vX4KUoqEw/fZgK9qBzj3VEQ0gMVBD3aMort8hvdp3lMHB4ZXnc/0Jf1vo2ZutfSR6EvcGdXWmdxKaIwnhNBRn+YQnkf1fqlbluaeFnPujHNe6aHc8CCeZAWOzmN7fhVyk4dxIshW1N9XDtPm7D3jG0MOO3nO7VCbsXmybO+FA== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:25 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 09/16] spi: s3c64xx: check return code of dmaengine_slave_config() Date: Mon, 5 Feb 2024 12:45:06 +0000 Message-ID: <20240205124513.447875-10-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Check the return code of dmaengine_slave_config(). Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index fcc1f16d3ad1..43b9792988b6 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -302,7 +302,9 @@ static int prepare_dma(struct s3c64xx_spi_dma_data *dma, config.dst_maxburst = 1; } config.direction = dma->direction; - dmaengine_slave_config(dma->ch, &config); + ret = dmaengine_slave_config(dma->ch, &config); + if (ret) + return ret; desc = dmaengine_prep_slave_sg(dma->ch, sgt->sgl, sgt->nents, dma->direction, DMA_PREP_INTERRUPT); From patchwork Mon Feb 5 12:45:07 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770551 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 BF03B24B2A for ; Mon, 5 Feb 2024 12:45:28 +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=1707137130; cv=none; b=rInvnNaCBRIn0a8hvxPlj/GK/Y2ollBkGV0zIUc2BWx42z0tcUC26iYFXEvLdTWDHEuRqJc+l/hMe8Bw4a+X+pgWRWoq4jqUIFF3Bwcgj93a35YJ28RHLu/5CU5VhNLaeK1u6svYW/oyMnvq6A2+4gBRN3IzOXTy+/tVPeo9VY4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137130; c=relaxed/simple; bh=bjmGyFjFxiqioAr4g1XSOAGWrQhhKSgwyKFYExhglLE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=YGHVTi4MVVJKEv2czwopHFR/qrSzoQ6Y8UhTvwRFDV2pz/rBmALkQZQ6yRsMvRg9zQZoexJ3LAvKJWAxb+y1fZ1WNSYDu8530YR1CDcF7smQQEF8aeeATRJQZAV/W5y+2p88p3eAU2+7T4fv1TZniqKptLhPw2gUUW8U/0fKrqw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=mpHrPGT5; arc=none smtp.client-ip=209.85.128.43 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="mpHrPGT5" Received: by mail-wm1-f43.google.com with SMTP id 5b1f17b1804b1-40fc22f372cso33500785e9.1 for ; Mon, 05 Feb 2024 04:45:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137127; x=1707741927; 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=JtonYnG1zvMSmP8RYe4qSrpkG7WWpwfs2mfkmLGPi30=; b=mpHrPGT5UJr0ovdh46vE30EcjQcYYa3XvWTOxkNGyHjPL7eDiaZmO03fDC0wBoBgC3 YJB03qV/99kbTQxc36QqNypUXjXmNoKQAdPhW5k0c+mwbUU98ixUV6nkc4yDSJSQysbD CNZwg7tdkP1eolshfqIU9GrwsQOU+Wimqs79/a3gMdPw4XWQt+b+Lf1vIJshb1IbLTAs PwWWBgkfHTo1WkBn8IRnSq2R5HYnvdDJPAgxIgYw1PvJXCVi0CUImtnC/LqZEqaecXN2 I/2h/c1JxSRDUDXRg8YUW54MqFYGxwkwXDV6CLDf/dMnij77NCcLt7SERVtNnCfFiSJd fCaw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137127; x=1707741927; 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=JtonYnG1zvMSmP8RYe4qSrpkG7WWpwfs2mfkmLGPi30=; b=Rj5n0A2o+DYbDNSnGfIBHoUbENwBZV1Ba1hXEeyIzbdMXY9uyXiJj/+hIUQwMYFQ4t GGwbFaM4LE9Jvuf+bXwtjXe8JUv0ZSAm70TySEShveg/5LWenDCJgUcThuYTMtUe43+b a/dJZCMltKcUlnJ+bNIv8snd7SZaTwtKwrz9dJB68rmjDyTC9Jbf+nEvM7xBWf3kUJO3 yU0gAnnxYiuti1S/fCyo+qNQ2Z4QH8YdX4/dMivbSkvLx3Yh87FRFrmv+Qwweu1zv4PM L3qfamK3OUQX2ibciMxgLXxWam8uZ/vJJPSj5lLUp1IbydS5H7ixPoQs+MU3Cx8+CgWX hyHA== X-Gm-Message-State: AOJu0Yzp9OVsdvDF4w0SpnLZg3s5ZVE1dXOb1Io7YccQaDKh38oiXRIo RGdWC+3Zign7bYXQt0GIYyzDT9XiVLCHmyWWT+iguNPOiwMh6mhYZSBl8Z/Xajw= X-Google-Smtp-Source: AGHT+IGvOiXo7HPcAuCueUfCXl+hW1dHjHJs0oFybOPNePVj78Eq7mqkrITmY1dHKEpvtlR/onCLSA== X-Received: by 2002:a5d:628e:0:b0:33b:1494:e4cd with SMTP id k14-20020a5d628e000000b0033b1494e4cdmr8738260wru.3.1707137126957; Mon, 05 Feb 2024 04:45:26 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCUnB2TnwxP2m+P+k2osg80LUiFMk8AYW9KKJixyKCil1SFvymbNwDnyv5aGOLjkdFIIat4WmSO7a4JXLHXn3VISSvM+7RVQcg0Pc0Fb9CO2WjD9q2jAPVAk+Y81aHewTEE1IiAUbWO2KdsWTh+EVlqaA26G3INEN+MW5DD//ZHCIBgpkDe+Q1yXqKZwi7+TZV6oZgWxpLWtlnC/vbOnnxR5hsTMrwcDUDdAcOhChiLGv2Cy+Fee/HbCH/Faz0FVfeE/fIgfQU1IizkzZZUkIk8biLIW2rCUJFI6sj/09hijvYqXudHO+D77AWOHBK8Jgy5aZtvLBRys53v9c3/ru4AGJtK+iGd5tYVFx0GPzDwqTGRYDcIPSQkBIOWaeLWHB0eNBql9MhxloRoKEj+AwfvCosH7A5tKS0fuUekbdm/MbC19l3fiGQbqdyjkJ62nOFmMU5HkynyBAYQUxajpBYqcz0FL95kIBqlij49YqJmlZcSsEDOd9WIc6DBH3g== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:26 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 10/16] spi: s3c64xx: propagate the dma_submit_error() error code Date: Mon, 5 Feb 2024 12:45:07 +0000 Message-ID: <20240205124513.447875-11-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 DMA submit should just add the dma descriptor to a queue, without firing it. EIO is misleading and hides what happens in DMA. Propagate the dma_submit_error() error code, don't overwrite it. Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 43b9792988b6..7a37f5d0abd9 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -321,7 +321,7 @@ static int prepare_dma(struct s3c64xx_spi_dma_data *dma, ret = dma_submit_error(dma->cookie); if (ret) { dev_err(&sdd->pdev->dev, "DMA submission failed"); - return -EIO; + return ret; } dma_async_issue_pending(dma->ch); From patchwork Mon Feb 5 12:45:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770289 Received: from mail-wm1-f50.google.com (mail-wm1-f50.google.com [209.85.128.50]) (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 1DB5C2D022 for ; Mon, 5 Feb 2024 12:45:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.50 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137132; cv=none; b=tBYO1cIxHsO9RTftGRGhc2HfLX3z3xJ9oSJECPEuqL8zduVj3DsLodwlTH+5X+S4HfIddlIctTgza05F9gEOiP5doajdZM5cFBekKlwxUSE/hkO4XkyRJrdxStwDNz7RAPkQu1oppVxjOAZgKIaIvwOmXe4jW6hejF+4fyfMK+w= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137132; c=relaxed/simple; bh=V9Bd3RiB2MaAfeHPX6FTsIe958CWx6bC/20prl79JuI=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=S+peZZ672/j3Xnns7o5slor+C6+3rLWUjFEVAD1F//Pdj2d+qHKh/TT37WZhbmOe5wjAoMIYwgGi9ySyf0BD3ELVLf9ajhfnU6Rewmc8hE2jLUBZWMUloeqvsq5x7fL8RBa9DXe2PwhKlBsca6bNUmNNmGRtwPZdXFbox5+0bsU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=aQG2RCUB; arc=none smtp.client-ip=209.85.128.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="aQG2RCUB" Received: by mail-wm1-f50.google.com with SMTP id 5b1f17b1804b1-40f033c2e30so39579225e9.0 for ; Mon, 05 Feb 2024 04:45:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137128; x=1707741928; 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=YZvfaKKEFRvfmSDe4W0tI5jmLTFflp/Gm8s0A/HkuUc=; b=aQG2RCUBU4C8svSaJbS+bD+syrZDfCap1VpQ7fJKNeyd4XgU0Way/WDJLvAWfjSrhb XtHj5Ts9G+I21l2mTP6wH/+g/QXSagHJuqwn7ZWYXhxxWtt+8LFy6K6FVKOl/zaNxn3t QoXJN4aDURrkod8Ggsvq04A1teb4bp4neeYJP806Ximyv6+84LEpUbGUCoeB5goz9AlH 456FwGUznZASEHrts+F78J1ZptJRilG15atC2DSdFfC2jiSp/VtYpialJ7ySM9P5jc/R BJsEHI79aqOOfoXXi394bZn8B/Wuhvh1/MCVvkkTmN80n+1s1z5wnkDJZSPSMDaeAH+I 8OIg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137128; x=1707741928; 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=YZvfaKKEFRvfmSDe4W0tI5jmLTFflp/Gm8s0A/HkuUc=; b=q/x2OXY44u/YM8T0zdRks5XAdQpZHby4BsLDTfDAGRIBZLdl0NCOfGpACvC7ZClhwh slSGfYiXCodlurHhbX8ldKsDQPVnFYVEr8Tzcz+JRQAP12M0k8Q+k6wtDxRqji25jii7 mVuz7XUw2QLG46mU/z4c+SYf8IRAciSiQEcnq8qxmSjI8diYhL+hzq93+aGiDNgS+zwu DfalDvWjfD0Bel1U8ueH5cOLVzyUzNm9/ojLLfbhtK+XqlReKUXho/UaxnBl7MjY2Vuv wMwBh50CTTj0wK0qJ1+saQ0OMJ7E0WL6koj6DPMNNVL/ndnkRK9wGgJq+g5v7LKtwwvy mlCQ== X-Gm-Message-State: AOJu0Yw2jRAynyfjZ34lUSwycBV+yU8h70Pm5KYGuFrPJ7Y2vKhrwaQq mlfBBvZPMKTa7C1rPvLDbOHh9dbOmhGIwnaithZ4F+B8apJvPD575YX8h/y1S2U= X-Google-Smtp-Source: AGHT+IGT76ECdpse5+FEjXiQNGRSUJHWZEYOj01Gi0tuS340doxMhwBI/+wWnW/4nShfRUwus4E5AA== X-Received: by 2002:a05:600c:20e:b0:40f:ccb1:7d90 with SMTP id 14-20020a05600c020e00b0040fccb17d90mr4588864wmi.12.1707137128331; Mon, 05 Feb 2024 04:45:28 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCVjJyP66heDdgX7AE01HkbJQ2VlHEGVuAMdf000jcqKqKCWDD6ajy1vpmjw/HT/oqqSheMnqZWnlI5Gu24ypc3Yp3DrG9CDy6JsHFBo/vKGpeNyc2wue5+Bfq/2q9cpy5Zuorl9hvv9IUl4Jw+AbCdaW1uQqLmYL/oC5BMEgHZZb7issd5ZW9PoiXyPw540IjIfcCKS1e5gUveV6ldLB73NDUtg3wdMHuk9LQIhWpPmoKLlMJo3tYiUprmQSRWvzMfF8e5EvVKC+qK4dPkLSa/iSxhBPvBDsk/fEduAg+Xpic/b4n2DrcGi6Eyq/0VO5H3rgh/EluNQha1oMRL4N/V0v2tItrAnQeEcn1AgLJ9dKUziwskkr2KWb7YoOLaBJCHeI/7d/piTASe19rnKdL0ohVLrlMNZ4ZZA3b5rl3Y6pk6RugmAWUrsC09LT4hhoUDSqs9H+UziXCqkZeOvFNtk0bFHL0eUPbrVOr0PUBGOHy8360tuR6Fq5IBmgA== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:27 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 11/16] spi: s3c64xx: rename prepare_dma() to s3c64xx_prepare_dma() Date: Mon, 5 Feb 2024 12:45:08 +0000 Message-ID: <20240205124513.447875-12-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Don't monopolize the name. Prepend the driver prefix to the function name. Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 7a37f5d0abd9..a51b5ff27d5a 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -278,8 +278,8 @@ static void s3c64xx_spi_dmacb(void *data) spin_unlock_irqrestore(&sdd->lock, flags); } -static int prepare_dma(struct s3c64xx_spi_dma_data *dma, - struct sg_table *sgt) +static int s3c64xx_prepare_dma(struct s3c64xx_spi_dma_data *dma, + struct sg_table *sgt) { struct s3c64xx_spi_driver_data *sdd; struct dma_slave_config config; @@ -444,7 +444,7 @@ static int s3c64xx_enable_datapath(struct s3c64xx_spi_driver_data *sdd, chcfg |= S3C64XX_SPI_CH_TXCH_ON; if (dma_mode) { modecfg |= S3C64XX_SPI_MODE_TXDMA_ON; - ret = prepare_dma(&sdd->tx_dma, &xfer->tx_sg); + ret = s3c64xx_prepare_dma(&sdd->tx_dma, &xfer->tx_sg); } else { switch (sdd->cur_bpw) { case 32: @@ -476,7 +476,7 @@ static int s3c64xx_enable_datapath(struct s3c64xx_spi_driver_data *sdd, writel(((xfer->len * 8 / sdd->cur_bpw) & 0xffff) | S3C64XX_SPI_PACKET_CNT_EN, regs + S3C64XX_SPI_PACKET_CNT); - ret = prepare_dma(&sdd->rx_dma, &xfer->rx_sg); + ret = s3c64xx_prepare_dma(&sdd->rx_dma, &xfer->rx_sg); } } From patchwork Mon Feb 5 12:45:09 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770550 Received: from mail-lf1-f50.google.com (mail-lf1-f50.google.com [209.85.167.50]) (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 85B512E416 for ; Mon, 5 Feb 2024 12:45:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.50 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137133; cv=none; b=O9Z3nnVIIQeDY4onaAPTCidZMbMUXSrk80h6lqaQTUlCiQHi3LnD5a40DHDqc98jA/GQp7A/4RJ20F76ob+HZnwfETqvx6ipbHgmoLFruUdI1AouMofJZU5oZRCzq3Ig3p/mdoic2sFL19ENG1L4dDrZ3MC94o/Pcn0Wood9stQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137133; c=relaxed/simple; bh=GGwL2SYhaZcDhgFBzqCu/yNX0n9hK+RzU0b+WitgpCE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=IN4tYfCDfEjhRRqyIc4EpHXlghQC9SpP284NRREXhOLDIasRl5S4K9KvBHMdNxBYMj//eW6jqSLKIJe9HCJj+ZH1pTdiN6moBNSSZ4/LeBnNJGfW/Md2ZN3iAXqydIn1n3uOifydh108bY1+dWvr0qIdRE95Yfrd1y/e10/pTTg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=yeCoFDZJ; arc=none smtp.client-ip=209.85.167.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="yeCoFDZJ" Received: by mail-lf1-f50.google.com with SMTP id 2adb3069b0e04-5114cd44fdbso1945134e87.2 for ; Mon, 05 Feb 2024 04:45:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137129; x=1707741929; 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=GeZOS2Z+VG4P/iRAp87EuShVVs7fGWt6JlzNyGBkAOc=; b=yeCoFDZJBBjvF7Evx+Gex05TZkjECl/Eqv/i1/P/eWT+aqXssDO0hZ4OHh3HfEu5n3 9modg+YVtYuUQvojZ5+8gCvPBjj4nBeTlnHK6LsLOzesZoii2p6fE05k2FcSc2dI9Duz encAMQkEIqXbnSwuy3RCtzoljYqg/6LBGShsTG9AyOwocXyJ7krjT7zEfzljcYYFpv9U zL9yTFVMMkaxDgOAGC63nwtKLtDltHD8+fMcYrO2WvSnk32ZTWWc45L58YWjjNuLEPOx Igu8ZE3WCLJwD5n+wog3Uys7TYiQ4LtFb7GfJnQ9lECC//is28pDUU4ns8A9soWLBtu6 CD0w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137129; x=1707741929; 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=GeZOS2Z+VG4P/iRAp87EuShVVs7fGWt6JlzNyGBkAOc=; b=p4RUzVCyiGk2+hzxvwEmPKp+QkSBtu5TQeyb43KmDqE2VRtoZby2MQxumui8PR5KdI r5IfJwuVq0htYfV8PhMOBHw96S9872YCcIrDESWrsdc9QTfh3lyjfnPZONGK1CCehNTi yN1QNjS3pRJZRMCp660Ms5qmu39r5B+ZGlQoKa4XSCKxs6VBXL9U/pFsrUffhw5+mYhc JxoIiUHQtNcI7O1AVJAzzFaY/FcER+I+D+VQT2Eyaa9GwVk4QLCSuqjPq9/NX36kom0D ll4WByj1t9tj1r+b1Q8VbA0bErZ+zswwm6RZBgd770wvoC7UDFjBiA2Ijh60fxCjy512 oHig== X-Gm-Message-State: AOJu0YxsY9u5VV84UOiZuiv5PzwIkZZWzPjjjY1UPn1r9x/E0XPO363j MAuB4bgEHjzVC7Qou+llcacfgTSzjjFWGjqBZ86Gn6SagYT8jdDj96KwkPyuNTg= X-Google-Smtp-Source: AGHT+IE1mZbxXVQps2jZE3OUPQWt1FaUJXLkEeIn02wh0XP0QYhwUFNqTyidAJP44tKJ7W72VSQ+Wg== X-Received: by 2002:a05:6512:b94:b0:511:5328:6f5b with SMTP id b20-20020a0565120b9400b0051153286f5bmr1349244lfv.53.1707137129604; Mon, 05 Feb 2024 04:45:29 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCWxyPgcgxfiE+kR7RyEi6zp53fCuacTX2viE9B5R90V9SyGN/7KRwimz7oLuTFX224e0mH+u/tSXCoq1cSEwBorkzsCwd3cexHCa40WP3rZhgXKNoXdij2lelf9q97xuZbLOwIqGQfF50hoWChBZC+0w3RSFZRBR4hWRKaWnXaV9FU6UpnAWNBP+B1UO2RWHTFKKEGWS1P4LwMUvxD0Mzn0+YAk0Y1j2WIYdb5assLOxXZSG3XZ8e4WfSJ15Bwf606rnIZHDSuWbd8lBOH5RZTR/03gsZrnRNoPZHRrWU+iLqrDJXp26rLMeQ8jZOkFjHrK/dmz6ulOICea4Uc1AO0brJm9Z14E1i/x2lLtCOfeyMfWeQ9V+j1s2kCxHjUEETJG5KgDBJF+B5GswQnoet8g3nuQl6u3BU4TO/dzk3K0ttwfj5g01hfGBsyNYSSHHKUv37Rz0YA4zsxAZ1FodqoTnjX7LBdvADzuv6ZsGads7ThFJrj0kRRm7tQgFw== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:28 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 12/16] spi: s3c64xx: return ETIMEDOUT for wait_for_completion_timeout() Date: Mon, 5 Feb 2024 12:45:09 +0000 Message-ID: <20240205124513.447875-13-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 ETIMEDOUT is more specific than EIO, use it for wait_for_completion_timeout(). Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index a51b5ff27d5a..fff430b9e849 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -526,7 +526,7 @@ static int s3c64xx_wait_for_dma(struct s3c64xx_spi_driver_data *sdd, /* * If the previous xfer was completed within timeout, then - * proceed further else return -EIO. + * proceed further else return -ETIMEDOUT. * DmaTx returns after simply writing data in the FIFO, * w/o waiting for real transmission on the bus to finish. * DmaRx returns only after Dma read data from FIFO which @@ -547,7 +547,7 @@ static int s3c64xx_wait_for_dma(struct s3c64xx_spi_driver_data *sdd, /* If timed out while checking rx/tx status return error */ if (!val) - return -EIO; + return -ETIMEDOUT; return 0; } @@ -577,7 +577,7 @@ static int s3c64xx_wait_for_pio(struct s3c64xx_spi_driver_data *sdd, if (use_irq) { val = msecs_to_jiffies(ms); if (!wait_for_completion_timeout(&sdd->xfer_completion, val)) - return -EIO; + return -ETIMEDOUT; } val = msecs_to_loops(ms); From patchwork Mon Feb 5 12:45:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770288 Received: from mail-wr1-f53.google.com (mail-wr1-f53.google.com [209.85.221.53]) (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 D5F6F2C877 for ; Mon, 5 Feb 2024 12:45:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.53 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137133; cv=none; b=YfWlcdaUPHTgfx/GiT8u77soOiHy5pFSEDZl8jJK1sumhRir9ydY2lYQlVGGPomTo8KGre6udFj9m7s1OuHXvYAhsZzt+LTx+kPa87O4xvf3eA12tXlwJ+pGfUncjLwY6YDH6eWfygGfm/IWOvh6IUx8cCbJOVRPJb7VNX7i9XU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137133; c=relaxed/simple; bh=+SyzjPnMT/SK+rtssQCg1kucXywzhF3SnUsMWqB5kHk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=fyK1QVZ4n6TA8fXjne1r1GWQhelqLEPXuWbhlq6rDDrQ+w6gvAe6c2o3/o/gWbgB2BKflRsXn7oZKuRj3te/kesp2AIPItZiMPa6Uh7GCIEKA3m5hV5YDjSfUQ9QFXcG48WOkb/cUF2ETy02y5Iib3z++DW4y03kLJw1QY1XaPM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=rt6X/xp8; arc=none smtp.client-ip=209.85.221.53 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="rt6X/xp8" Received: by mail-wr1-f53.google.com with SMTP id ffacd0b85a97d-33b18099411so730033f8f.0 for ; Mon, 05 Feb 2024 04:45:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137130; x=1707741930; 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=pMdPKuCa+A0pku+lpKMRGIhG3kodHHE5iXFOt26r9zs=; b=rt6X/xp8dU8Jcuqj0H9VP/pZ0rtbWiSR5mEI1wWqNQZacpub6W0e8fIDpKGE6TDon5 rxOkOaSJv5GkzCPf5Sq+Kv+j50iIbMYZhBrKGcBAzQPHd9+4HR25MYnQHYNCTATgWoNR su+2CpqPd1AhzQK8WJf4reFISSvpe5QoBBCEhUyoMzXo7ryoNTV9RIecHVXeR2HhMpcg r6p3uSSDMDN7K3iLmw+ZMIKRuhvSYaevkqrYU5tEa2+zFbqHLgDf9UY64ALQgAyDyzbF Pi+g6pGKY6H5Bmp1z+KWyndgbn0P7VQFI0u4t2Pu7KnPEP2JJ42iU5pA9S3orK1y9yrc xVBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137130; x=1707741930; 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=pMdPKuCa+A0pku+lpKMRGIhG3kodHHE5iXFOt26r9zs=; b=ovrE5GGTLqbTjxewWKWVAsJL0pI1JATnvtFhiqQolot9dKayKy1rSG0T84D06+P8aN GNh1TCKgyyroQ4lMs8O6ArYwtGirWUPHIfQxsCDY5M4wzYLFCQBFji5naUBnw1QjqK5J 4P9nxZkbYK8c0W9uZgJFQN2t1BRrT3KuTbk+NFh7poW/X8vdVa3+u1cGPEgY7g09JagN h6pUBGPL9mhLzpo752MPb24BkJlOzSYfHCN43GV2Ed7rZbNw6ETCvQA3cTUOQWujHoJa cZK/kgeS1YZdKfUh2Lj6FIjiP6oY/0LZ7dyw6HkgkcwBKTXioDOe2SJF6pc10kCFOhuH Pmzg== X-Gm-Message-State: AOJu0Yz4HpJvjUl7SwU34vUs5MI8E9xYuIzCvA6xlur5EbGQUTFCeag5 SjH3a4I9A73NaOEFEhll5ldAF+pT7nJ1ACIlVr1fbC6CZ4p+4NrO6BvD69TgarU= X-Google-Smtp-Source: AGHT+IGossleR/t3Dta3NCg2Z2WPIoqoJE6vcP3vID1Krxh75KjzP3TERTiV74XdiyGuaLtdV0xObw== X-Received: by 2002:a5d:608e:0:b0:33b:3d6f:7a2e with SMTP id w14-20020a5d608e000000b0033b3d6f7a2emr1870007wrt.49.1707137130247; Mon, 05 Feb 2024 04:45:30 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCXg3qJOH3WJfmlDrm2ZHHrIR7JlWC3n66rAo3+txIBb+YdC1ewlKXR6QRNOinsD3/ORZJtHBzvEvZ/0t1Xnsi1Pc7WBZOViqG6TZhbIrRxPFDFOUWU6t2Aw6WbbTTLkpru1N5NQP1Jm0gPjsWkzx9ma/8bhKWO1YqaDBGuImg+p3Ve+if6M/tXtMWD1B9t1NcnrGaHpoyDuT47xg7eRyMnefKyv5gYPFUOcY6ypLx77FoIe9+ovMJMfwGhXT0rB04bv1GFTgcTlIOqrVbdHhRk1CiLtcQofE5Y6S1+sKak+XYw4qAw0Dj6Re0R1UniB77mBjiopJW8hEqafNZ1d4k0xSjQIRaGwT6g+0iHZZC8BcP/qxQyIFX+nSe/ts2IGcVeLhX0nWuvsQ6J6KgCPkWT8Df3lfnsPT7J5/qzXr56uwXt1/XD0WLlimQ4/XNgc1AwNjJvlRRcOCAlciIkOHFM+NA3Nbk+2bbFTkm6UybgsBtWaxiINQSu2XSz9Vw== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:29 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 13/16] spi: s3c64xx: drop blank line between declarations Date: Mon, 5 Feb 2024 12:45:10 +0000 Message-ID: <20240205124513.447875-14-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Drop the blank line and move the logical operation in the body of the function rather than in initialization list. Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index fff430b9e849..1b84f5fdebce 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -1320,8 +1320,9 @@ static int s3c64xx_spi_suspend(struct device *dev) { struct spi_controller *host = dev_get_drvdata(dev); struct s3c64xx_spi_driver_data *sdd = spi_controller_get_devdata(host); + int ret; - int ret = spi_controller_suspend(host); + ret = spi_controller_suspend(host); if (ret) return ret; From patchwork Mon Feb 5 12:45:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770549 Received: from mail-wm1-f49.google.com (mail-wm1-f49.google.com [209.85.128.49]) (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 C664632C90 for ; Mon, 5 Feb 2024 12:45:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.49 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137134; cv=none; b=Fm+o4Fm/hByrqxiAmRlR7PBnbIy3fQzIBToRwBPtffp6aTJ4UkVwwz4maahtPtV+kVsKddQ7bs9Ws0+gR2OUak8Fv/kpmUydHAZYClD3EFLpNn2pRWZmnCZEXOPg0HWjHAu+wkZzZwBblILyFNvqQbo2MPem7N4L09jFGT5ztCE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137134; c=relaxed/simple; bh=bkpMwYn8nbOzpgIiboImEfaN66xWiWIf1hOKEtwBN3Y=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=aJ8CoxV7YBWr7wtQMTXJ1gLEe5u20gVAJ3Z8e10Oz8zPGW/OEfptcln1wo1FFF3SqV4sG0kXlPEOlqhVtTTNfJDv+1G4VN/PQF+WkYYIkA6rQgvC8v/+EOGulGwKvkCe9knPuAaUD8LAa0BN3Gsx1fFaTnhhgRGymS1WoyF3JWk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=u5GkOHML; arc=none smtp.client-ip=209.85.128.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="u5GkOHML" Received: by mail-wm1-f49.google.com with SMTP id 5b1f17b1804b1-40fc654a718so25810685e9.2 for ; Mon, 05 Feb 2024 04:45:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137131; x=1707741931; 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=mnMYlR6fQ0mQVONi00LlSkAABzsjAbHvknmZ+n/K3Yg=; b=u5GkOHML/lUnOxFnDqmxx1UakMn4WncdxbOWVD8cgoo+Bn0dQ3CZTG+z6rG6FcKyzE LfmNUbbFGHPjrJ2otkf3TEMJ9vZxxmfN77xQLErCeZXj8SLyziv7mWLLwPujwRFdhflW hX561e2sqjT103umPAy9cJNGFyCAVITxpZcdCNliD1K56GpoB+1zUq0j04p2lyI3vVBi LiQDJOkDDWekRMhD6lxlHuMta8ih6P0SBgjsUjy8dDX4/COJ9yZPdu10DJgXdKTdjVLh i/gY8qDEiOZtn+SU1HD9gcKvf3J+s7nNuXMLlLeUMmJaxLtEti6SlQk4szuzcHHYhsij 9SjQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137131; x=1707741931; 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=mnMYlR6fQ0mQVONi00LlSkAABzsjAbHvknmZ+n/K3Yg=; b=ASo3tnm5xu+6e57MS5/bNbEbpwhcoI2mLX62QuB3OnKmDa/w5x5FZmEpUYQsQS4Mzl vTM5cxQWy6R92YXI+nZPv4/pyCO+Y+DkE4r1vdJmJ7wVQo1uvtqF5ktgqHooXsHtvwnA IsU+z2rI3vtymq23oEmq1wQfgYiKUvBSxz0SMiFsuF6kU/JMytxUw+c0oJke40rk257O /lwKGptlMOQFrkQXSjvG29pO4UhqUq2h+7KMappkkS/wpuz15orW/9CQKJjVYVi/Db/r lWeqEETxT1WkjS7gSA25spW/aQ/WDuqXuwi7lqg5iy1Te2da2hHqJk6GQh/2/SDQa8IQ 1hkQ== X-Gm-Message-State: AOJu0YwfD2g/bkZzBoOfUVbMq9Y2+j9Z/QxbDfeQt23RUl3YeJX3ntog Ey0b1WSQBWetk3NF8EcqohbqC2FnXvXlE/t2tcECpg2sjMRzoa79DjPvmK9FG/8= X-Google-Smtp-Source: AGHT+IHh2/7KX6KKpvaNwnmk9gubBGVZ9ofeLerSnDyELk8DCSmaQzMWdOz1adXh+ZdWJvshWkpSGA== X-Received: by 2002:a05:600c:3585:b0:40f:c234:1fcc with SMTP id p5-20020a05600c358500b0040fc2341fccmr4358107wmq.29.1707137131112; Mon, 05 Feb 2024 04:45:31 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCXcXFLJy6cfNdvSiZapC8x0gY2p2hCeIf/v6F/VZuAJu2HP1lwRIRqcyrhUsMDxQiJ9h10Rszuh0YKKJXHLP4Y4qai7EYJnqdHc2Kcm2fNELedi2qdVc2nSGdVppMbXle4S+bJysxUzFnWoRD5oVwNbG4ig02R4mPkWLoqpL6N0RawwU7U+oq70BZJleN5TCYzhoAeDdVexwYbEg6qh/pcIL1Euw4mYDTDOa1Q8kZcufSB7BPaVy4Dq+6pAzd9Hgmdfm2oxXmOmkYriteNl+xq6ahR75w1JqoOG/qmTLGQgW7NVtrT+tt+/ju8W7oh2U/ZqUjPtvVfQ4qzvuHCBxOWE8lTJIrPFt9leSmy29qKNjrkOmtKhPs9XH6UxdBnGzxezV4qEQXa4VBkQpJIDt8C+KKSCUelzDRdT4bFxW3TGnQZoq/W0h98avBuzO0krl7TZ1+F4Tei77sEFQaVpSWJPSQ5l3959S0B+NO+tMXQYS1FdoOo31JNjWysPSA== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:30 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 14/16] spi: s3c64xx: downgrade dev_warn to dev_dbg for optional dt props Date: Mon, 5 Feb 2024 12:45:11 +0000 Message-ID: <20240205124513.447875-15-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 "samsung,spi-src-clk" and "num-cs" are optional dt properties. Downgrade the message from warning to debug message. Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 1b84f5fdebce..a103d9e125b1 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -1109,14 +1109,14 @@ static struct s3c64xx_spi_info *s3c64xx_spi_parse_dt(struct device *dev) return ERR_PTR(-ENOMEM); if (of_property_read_u32(dev->of_node, "samsung,spi-src-clk", &temp)) { - dev_warn(dev, "spi bus clock parent not specified, using clock at index 0 as parent\n"); + dev_dbg(dev, "spi bus clock parent not specified, using clock at index 0 as parent\n"); sci->src_clk_nr = 0; } else { sci->src_clk_nr = temp; } if (of_property_read_u32(dev->of_node, "num-cs", &temp)) { - dev_warn(dev, "number of chip select lines not specified, assuming 1 chip select line\n"); + dev_dbg(dev, "number of chip select lines not specified, assuming 1 chip select line\n"); sci->num_cs = 1; } else { sci->num_cs = temp; From patchwork Mon Feb 5 12:45:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770287 Received: from mail-wm1-f46.google.com (mail-wm1-f46.google.com [209.85.128.46]) (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 AAD9733CF6 for ; Mon, 5 Feb 2024 12:45:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.46 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137135; cv=none; b=hfWZwdNYO8/49JYjsjheLZmoE12HcSBJn4Z+FKLhZT8opmOOg7pOi0PdjC45ri1Jw5wFkNq1y1ZzzUY4tZtphHkhtn7t4W04UaboMWfD05RuWCqbpvqsuuVD7SdcbAPaRFy0rV9vZc9emXq9C+EAmicxmoxSoreyttVzZLGGgbA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137135; c=relaxed/simple; bh=nMWHTWDw4FSV8N1BenWt9bH//miQS2pEnl43CiMUQ1I=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=kcPRegjHRWqVPeSjEoIAAVkbiiSsH58ZGJ0FpV+OpbI8xXsXr0uL7Q6L5/Z/eddElv40IR8J2/Vd0fMVytS4xPlLYMyFny1iLnN7Y2Xivi+OMuEChV4OhxKnvaf/Tj7r0nR/24YH3sBQpe2NqyrIAqFLHzaFrfGFw4ij9l3omz4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=LLBP+mGt; arc=none smtp.client-ip=209.85.128.46 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="LLBP+mGt" Received: by mail-wm1-f46.google.com with SMTP id 5b1f17b1804b1-40fd280421aso15294245e9.3 for ; Mon, 05 Feb 2024 04:45:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137132; x=1707741932; 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=YQXkAU+74DrdhIBCBHKX2MNDRgI/UgoC8DKW9ZMunl8=; b=LLBP+mGtvsPXlZTkgRDGKNLgTeM2KZMJxHpdMRNYmtF6WbF+/0lgpCwwvuK7tTdszg pajfrOsMFF63xL392rkiGXf3Txgl3B5WiKII87tqKqoTU+cAecTsnY8ORQW3gObU5I8e mymok+Ngh6X7OkGOsGs3grCjkN/0vdSDUBEI6BZ0liCqSu2ALpjRVMgK6HqZo3nnNI/P zPZgzjma99WPpmysSP+FZJSv6rv+IlDN3vtWsKCBZsdF/iCXwUC1kqNZtlaNQXL1UfS2 rwXVaFBJItONKVJ8+9pcxOjI1uulUI+F2NmYZYXrQ7yRKbIEmQVP9+Maxj7GlXh5pg57 fOyg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137132; x=1707741932; 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=YQXkAU+74DrdhIBCBHKX2MNDRgI/UgoC8DKW9ZMunl8=; b=FxIo75EVN8xQZEOwoKcdtfZ6fgeYANXlRjn1z4Eubd1cIXflsvo2rO6cYpz6ylboiF Lh0pPBAEsMdEr0U+sAbojd72+TGWzA62dqQcd0exokHISe3H9Q+4iklXGgse3l4AS01W MWJt97UJSC+QBeOVkpqW6vOh9LLzXGwvK9k+9CpVePWHO2My2Ymxncp48xhVu6ObaNkH pstE3TgDqBd1cASfGDAvUYke9/7eGAozLmSiNNeSeNLs2120N8IYVfaMg7IsC3I8H0NK bU2ZWynXErI8Kirsn9R27UrzC58aWt7wiYeI9w+Ug6AaQB1080yx/J2Q7POgGR2bS4YY 2/Mg== X-Gm-Message-State: AOJu0YwBQa22XSDh5HZ3n7ltCXZiIaOLVnGbDVbO6EtSNA1ug0gyiIKK yO254ZxNAA8/IwaTuLc8HNycGHA6DV1Ni11kP4x3DoYOGfXvsk8QloUZhyEkrSg= X-Google-Smtp-Source: AGHT+IF7w0SrhbwiPOGLZfv8BIa8of6H+8D1PRONLjMNE0XBKdpEovxHCLmvEEYujDtqITnemVr/hw== X-Received: by 2002:a05:6000:1ac8:b0:33b:376b:8127 with SMTP id i8-20020a0560001ac800b0033b376b8127mr3215935wry.54.1707137131953; Mon, 05 Feb 2024 04:45:31 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCX2qttf9AlWRBYLbY1d8gb8YqqL+/qbSPDmU1x/m+yaCWDvy07L1ROL3wauST1rGVbRb66EjPIOtlB4n9urmuC6jc87wSzy520b53wDeu2QKN5XqjMaIu+PEGXEtn2PsEEzukAyU3GBbZ6Sh3d1fbai9c99q0GXpW16SJhUi83MA6NNr9cmF+rJT4XDUjW5qAFbK9R8q34VF+gfJsgg7eRJXfTPV1PUwy9A0lDg73R8jnORoZs/RgQ/isCVKdR5yhkorP8qgWX1fPZZns0wex1myEuPyXCjGY88FP1yYOXpvl61hB+5ajhvUFWloaH10FTY6sjpoBbeyXa9UIC1FFORmZLspdFVt5U5PcTM43LzYsuLRANG5F8KTV46cse58Gk5Es8sgGXJjzTw1u2dCU+r+KNu3FOyvQDYTy3HxeCFEIupExIgi3oKRP7Cb/h+ihjduDAV6bGa0+o0EHVLO9kjnYGia/OhRedv/6a3n4v0eIkr9EqK8B2OBiJUhQ== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:31 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 15/16] spi: s3c64xx: remove duplicated definition Date: Mon, 5 Feb 2024 12:45:12 +0000 Message-ID: <20240205124513.447875-16-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 S3C64XX_SPI_TRAILCNT brings no benefit in terms of name over S3C64XX_SPI_MAX_TRAILCNT. Remove the duplicated definition. Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index a103d9e125b1..ed0b5cf8fb4d 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -115,8 +115,6 @@ #define S3C64XX_SPI_MAX_TRAILCNT 0x3ff #define S3C64XX_SPI_TRAILCNT_OFF 19 -#define S3C64XX_SPI_TRAILCNT S3C64XX_SPI_MAX_TRAILCNT - #define S3C64XX_SPI_POLLING_SIZE 32 #define msecs_to_loops(t) (loops_per_jiffy / 1000 * HZ * t) @@ -1092,7 +1090,7 @@ static void s3c64xx_spi_hwinit(struct s3c64xx_spi_driver_data *sdd) val = readl(regs + S3C64XX_SPI_MODE_CFG); val &= ~S3C64XX_SPI_MODE_4BURST; val &= ~(S3C64XX_SPI_MAX_TRAILCNT << S3C64XX_SPI_TRAILCNT_OFF); - val |= (S3C64XX_SPI_TRAILCNT << S3C64XX_SPI_TRAILCNT_OFF); + val |= (S3C64XX_SPI_MAX_TRAILCNT << S3C64XX_SPI_TRAILCNT_OFF); writel(val, regs + S3C64XX_SPI_MODE_CFG); s3c64xx_flush_fifo(sdd); From patchwork Mon Feb 5 12:45:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 770548 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 7F7C538382 for ; Mon, 5 Feb 2024 12:45:34 +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=1707137136; cv=none; b=RQv4/ZM34ujU+y8H9SvfgvAxBgH5A3BL7RacmZufHriQdtJATdcHd3MwxeNmUt0aalMbLXNdS9JyhD8Z727w5+4PdiXEhtXMvSJSymPiOTav4KwICJQpkIolBHXgVK1YrGKbVT0RorjR/RyfSxWhF6RXREBIqD8gIQmmhyr7KcA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707137136; c=relaxed/simple; bh=pcCRvLVnc0tf2pnRSFEh9MBfccVf+WuKitDBj59DJ6E=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=bkn9mCvplqZyXyMQo6p+Vg47OnZvthV6YLH4yB5PvK1pGhxgF5sXWP2OwGoTwBliLvaSxEoR/Bs62Io8bWMJobcN0aI3biXdzWMh1+2zqHu7GbChRXvgagR32NrfdpM/BFU1D6Df/kF7OVwpiobYrYAZx3ZvNYreR4asc1MH1FM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=FVBxkbVf; arc=none smtp.client-ip=209.85.128.47 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="FVBxkbVf" Received: by mail-wm1-f47.google.com with SMTP id 5b1f17b1804b1-40f033c2e30so39579885e9.0 for ; Mon, 05 Feb 2024 04:45:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707137132; x=1707741932; 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=bTE/0vC7WxQ0ABd9oJxLbbsyqbh1xb/MkKSY0UL7qyA=; b=FVBxkbVfzVMLv85O573n67blq7BXn81h9AvQqXIwy+pfbB73S9l8Ila5cm4GUTrpBx CkBzyvMYWb0fetwC23knjzNPMRB5G1rKf+QdmPfKfocZPVM+yJHK+zdsXhpNHIZbaH9G yCXar5CVmBA8d9xKdy3ve0XrZaq6YcMe50l4Ss45BI3WJqWen/xO4oJVZuDe16CEmqNw MPHyDqJCPbAW05iGRxdqm8bp5UdKHzCyp1ssEik20nw9L9FVf9c3Nfw3ZIGPoAwypUAR 18juVE91uodiPgrzWYI3yC3kORSU7iRBLd8F3nprolKy57wBykA6bQhVv8CPcae1bDua ifqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707137132; x=1707741932; 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=bTE/0vC7WxQ0ABd9oJxLbbsyqbh1xb/MkKSY0UL7qyA=; b=pQlXit6RbxQqBAaxMa6wX1ArD74AERWeu+cBBnKugPztSW+3aYTpWB5NzUqZZBN0XZ xd7AVAUgqUuaPWNKdONpQES574DHrxtmAexvUczeBOIN32Hy9ndOeGLvqDvdPtLGupcc GSLiZgoT1HNPOEaMGjs5RbSLUPP8ZgOEchhLVHWjwsXk4d9M2ThDfcvrtinZdWVU7sct b3fAuWg5VxX02kpkFdMdxCJWVPa0qi0GJz7pcbpSIKFMQ47+OG9IFSbtoooPFIjIVXrm HUcc9ZLL5ye96iOe+I3+jo6whjAnZYoWaPu0B1sL3CJ7oK0CFN1jROM9/rNtCemQ9VFL rGCg== X-Gm-Message-State: AOJu0YyStucO9dbZ0d5H1wENZVC3ROTxma2wLgWApTeamr4zgDYhvr0C nhgqxB3mj2nPXDB7n7pX6Ba/VlVlyt41lCcgOfQBk43/5g1uW+St1f8QTiGKRTM= X-Google-Smtp-Source: AGHT+IHtAALc9fR7T8Hi/V4r24s8Ve4SlEF7nzbMB27mSpni9V8hYXrKvi9LtEVW3ATD0zbAXNwfUw== X-Received: by 2002:adf:f7d0:0:b0:33b:2200:a076 with SMTP id a16-20020adff7d0000000b0033b2200a076mr5180536wrq.8.1707137132629; Mon, 05 Feb 2024 04:45:32 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCXhQbKNIMYyPNUUsGm6OpaKLjLncRljyTEjlpzOjoSmQIPeuwg/T4NPRLuMf6tpq1JIJbVpYxGfT1Q6bpi3ACI5BaL3xKWtECi+tnoRq9br8cJyaWXuFeha4+PIcXC7UqZGMM4j973PqaRzOVSfcW80PE0B+cg8VyBqLyvNcf38VkSZP40ORSRftYfyKPX+zOYiSjctdWrghn92yPmJBgdUcP7YIORCQs36bn0arczXNkLUMI8vtfp87jRkjjOVUDa9yNCU/BAV1p9om6oPPFrTJ1qmX/NDnf/1QTV01BP3vPaV0IqzUnJUs41U0VUWM5hzhkNflSAGocusT1q11OktudMn1GxYToMhFxIO7ZmKTOPvpbn+nFndcFhKUYJ4ecRRvTHdRZzOGjO8Ae3dEjFCJajPhsCJNY4g3muPmaTA54+OEZ8xLEbKN1xqlCG5ZmCm1RKQZ+cTeBewO6tff9YuYGQPhThYaNcfS2g6rbEUhK6TJog2V0Awhqdrag== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id n9-20020adff089000000b0033b35da384fsm3650812wro.33.2024.02.05.04.45.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 04:45:32 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, Tudor Ambarus Subject: [PATCH v4 16/16] spi: s3c64xx: drop a superfluous bitwise NOT operation Date: Mon, 5 Feb 2024 12:45:13 +0000 Message-ID: <20240205124513.447875-17-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.594.gd9cf4e227d-goog In-Reply-To: <20240205124513.447875-1-tudor.ambarus@linaro.org> References: <20240205124513.447875-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 val &= ~mask; val |= mask; is equivalent to: val |= mask; Drop the superfluous bitwise NOT operation. Reviewed-by: Sam Protsenko Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index ed0b5cf8fb4d..72c35dbe53b2 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -1089,7 +1089,6 @@ static void s3c64xx_spi_hwinit(struct s3c64xx_spi_driver_data *sdd) val = readl(regs + S3C64XX_SPI_MODE_CFG); val &= ~S3C64XX_SPI_MODE_4BURST; - val &= ~(S3C64XX_SPI_MAX_TRAILCNT << S3C64XX_SPI_TRAILCNT_OFF); val |= (S3C64XX_SPI_MAX_TRAILCNT << S3C64XX_SPI_TRAILCNT_OFF); writel(val, regs + S3C64XX_SPI_MODE_CFG);