From patchwork Thu Aug 10 09:12:45 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 713158 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 84584C04A94 for ; Thu, 10 Aug 2023 09:13:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234686AbjHJJNb (ORCPT ); Thu, 10 Aug 2023 05:13:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40136 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234698AbjHJJNE (ORCPT ); Thu, 10 Aug 2023 05:13:04 -0400 Received: from mail-ed1-x534.google.com (mail-ed1-x534.google.com [IPv6:2a00:1450:4864:20::534]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7DF042D7B for ; Thu, 10 Aug 2023 02:12:52 -0700 (PDT) Received: by mail-ed1-x534.google.com with SMTP id 4fb4d7f45d1cf-523643207dbso796429a12.3 for ; Thu, 10 Aug 2023 02:12:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691658771; x=1692263571; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=2tF/UykYBSS5il9uXSjCsz0BSK47V9bZY9dMBZBHwCM=; b=Omi3/tkSRgFfWFz5TU3/glLgHe/N/sxie8IkJQRtOfCCzWVEjQR+W6CBt1eRbgOZfA nSTEcYf2a9/VRoSVBSrbaxhJQ4ooFAe5nazCqlyCWFz3DXqss/iCO6G1+2n6eLu/4cNa MxOV7IQVAnkhWVvyXn5SkY+Wi6C3g3yDPlgLFcDnYofNApG+QBC/GAETWxRGYCF0oIVh V9mCG/81U2ziw+8NPtRfpaAgnkXVnQTM72dZFeLXZpUKysceyG5yiDRJ4g0IQXFX91RH 2/xNq+za9s+oXmSt99zEQthls14X5s5w0SpPRBhv4QVnTepwrfmm59qbjovM+S2gq33G bTJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691658771; x=1692263571; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=2tF/UykYBSS5il9uXSjCsz0BSK47V9bZY9dMBZBHwCM=; b=EtUDiBkWNPENxyWKwk49TWmc/uvnkCaAu6//7ZtiJp9orD2CaHG8gFoYke8U37jZnt ixzsDUgTRBi1340EZpJ5GfaA6iUqdWmw6OpNcsDww1vwZSqwRWjdRF+0arobVRNlgqe9 HTNPjW4sE6yauKQQzZxpeMffzGHpTaXGNVcp4Kr1A1PD3RUmP98E9w/PiYdHwqmEsJh6 7+jK5uKyRSiUb/qUQqmAP9z+x+kHb2AfK187jf5EvaOYfoCJF/ya3x0ztqSMZn+15b3M jBmzZYfze/Va7Cc3uIy3oOYlT0ZjmcM/WRJ9QH8pzkCLHxU6ogNkmSmRPMQvdISIx0Zs r+Mg== X-Gm-Message-State: AOJu0YzpbjGrqLnZK4fxOMVb7Qgnbts7iQqg2ef3obtaYUmaYURHBn1W 3qASPbslkLR69zXA/U5w48jNxw== X-Google-Smtp-Source: AGHT+IFSpZpedFWoUrxz4TLziYvl5dMKs7HeE6VXyI4MkrnHmPOf5vv/Jeg4jkdwCZhVlShfwLlJEw== X-Received: by 2002:a05:6402:6c9:b0:51e:3558:5eb6 with SMTP id n9-20020a05640206c900b0051e35585eb6mr1660739edy.3.1691658771138; Thu, 10 Aug 2023 02:12:51 -0700 (PDT) Received: from krzk-bin.. ([178.197.222.113]) by smtp.gmail.com with ESMTPSA id m8-20020a056402050800b0051ff2b6139esm538889edv.5.2023.08.10.02.12.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Aug 2023 02:12:50 -0700 (PDT) From: Krzysztof Kozlowski To: Sanjay R Mehta , Mark Brown , Daniel Mack , Haojian Zhuang , Robert Jarzmik , linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Andi Shyti , Krzysztof Kozlowski Subject: [PATCH net-next 1/3] spi: sc18is602: fix Wvoid-pointer-to-enum-cast warning Date: Thu, 10 Aug 2023 11:12:45 +0200 Message-Id: <20230810091247.70149-1-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-spi@vger.kernel.org 'id' is an enum, thus cast of pointer on 64-bit compile test with W=1 causes: spi-sc18is602.c:269:12: error: cast to smaller integer type 'enum chips' from 'const void *' [-Werror,-Wvoid-pointer-to-enum-cast] Signed-off-by: Krzysztof Kozlowski --- drivers/spi/spi-sc18is602.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/spi/spi-sc18is602.c b/drivers/spi/spi-sc18is602.c index c67a24daaaf9..9f98bf350697 100644 --- a/drivers/spi/spi-sc18is602.c +++ b/drivers/spi/spi-sc18is602.c @@ -266,7 +266,7 @@ static int sc18is602_probe(struct i2c_client *client) hw->ctrl = 0xff; if (client->dev.of_node) - hw->id = (enum chips)of_device_get_match_data(&client->dev); + hw->id = (uintptr_t)of_device_get_match_data(&client->dev); else hw->id = id->driver_data; From patchwork Thu Aug 10 09:12:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 712566 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 10922C001DE for ; Thu, 10 Aug 2023 09:13:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234667AbjHJJNh (ORCPT ); Thu, 10 Aug 2023 05:13:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47406 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234700AbjHJJNL (ORCPT ); Thu, 10 Aug 2023 05:13:11 -0400 Received: from mail-ed1-x535.google.com (mail-ed1-x535.google.com [IPv6:2a00:1450:4864:20::535]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 136E330C5 for ; Thu, 10 Aug 2023 02:12:54 -0700 (PDT) Received: by mail-ed1-x535.google.com with SMTP id 4fb4d7f45d1cf-52364e9daceso782229a12.2 for ; Thu, 10 Aug 2023 02:12:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691658772; x=1692263572; 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=Pmjanwa7FaMhLMYXioPiW0FxTVwb1CQvmQDfKQ4w4Mw=; b=gRAU5xo0vansbTMZQipPzyKv6BUKttSBM0Z8Pwx0oTf9igSvGRzAwBhNJRGD+Wxbfs ILsx15h2SFw3xik4dIsMek8gEWgmzfuM7hOHHKUtAqRaj/AWMrBcrt5/Y7gY9kHcDmVC wpICj2aLXGy0eNaosNro8916UuX0wHTSncHyO6vo3B8/cKGAsbO+aVAxs8H8WpmpVfx1 4vNNp4/Y60r04F9eLYpjuw4fXenTZuQ7kXGf2Kn/eRJKLFkWcJhi8qShflFyWtv9Yu8v imKoZi75xDAkzArXNLNc3Su6Mbjliesx6Q07McCS862F3+8mPkcSQ6q4n9qGf4iOp52U AeDA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691658772; x=1692263572; 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=Pmjanwa7FaMhLMYXioPiW0FxTVwb1CQvmQDfKQ4w4Mw=; b=YrQifxVzgQoHfURSXZ+In6lzz7xxJn15d+NiKj8OLmGHi2f3mhe9QRKDN6FaFdcg1A Y+NjrnQ6HBSZhGAeMG1nz3q4Y2lKeXhOgnQDIa8RUMecPBr0TfWuxQpo2YlpuFHXKHw4 TM0g2Lg/KHbQ+CmtxdcySsY941k58vtOhTg69Kn0s4ELEVowEO4xLShgDddl3Rcmfn7G 4057ikjvfILZW0JD8PsjJ3WKQVfvM1/d1JbSnxJgaTEuEq2q85P4MF86ZsCCn4IZ4sr7 CCgU+dtn2L5FkhXo1uuPOkwdZdOfM41cWMlsECedZ6Dt1Zz4x3UFq9IP4EpcqJG5+IMZ yf4Q== X-Gm-Message-State: AOJu0Yz8mSuTcLmeA+GPITtIn/b63yqRjvi3Y4nLvQT3XAyDOOUm/3Rs 0DwdHuAbs666IE13mUTCoO2BZA== X-Google-Smtp-Source: AGHT+IE9OU+bBFAAhGPvuibR9qpZs0k+oOpD0hwuV9OF+L4V2bjPKmr19tJP8nJNFn1nljMgKOjwOA== X-Received: by 2002:a50:ec99:0:b0:523:372c:24fe with SMTP id e25-20020a50ec99000000b00523372c24femr1332231edr.39.1691658772644; Thu, 10 Aug 2023 02:12:52 -0700 (PDT) Received: from krzk-bin.. ([178.197.222.113]) by smtp.gmail.com with ESMTPSA id m8-20020a056402050800b0051ff2b6139esm538889edv.5.2023.08.10.02.12.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Aug 2023 02:12:52 -0700 (PDT) From: Krzysztof Kozlowski To: Sanjay R Mehta , Mark Brown , Daniel Mack , Haojian Zhuang , Robert Jarzmik , linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Andi Shyti , Krzysztof Kozlowski Subject: [PATCH net-next 2/3] spi: pxa2xx: fix Wvoid-pointer-to-enum-cast warning Date: Thu, 10 Aug 2023 11:12:46 +0200 Message-Id: <20230810091247.70149-2-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230810091247.70149-1-krzysztof.kozlowski@linaro.org> References: <20230810091247.70149-1-krzysztof.kozlowski@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-spi@vger.kernel.org 'type' is an enum, thus cast of pointer on 64-bit compile test with W=1 causes: spi-pxa2xx.c:1347:10: error: cast to smaller integer type 'enum pxa_ssp_type' from 'const void *' [-Werror,-Wvoid-pointer-to-enum-cast] Signed-off-by: Krzysztof Kozlowski --- drivers/spi/spi-pxa2xx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/spi/spi-pxa2xx.c b/drivers/spi/spi-pxa2xx.c index 1bab18a0f262..21f156587669 100644 --- a/drivers/spi/spi-pxa2xx.c +++ b/drivers/spi/spi-pxa2xx.c @@ -1344,7 +1344,7 @@ pxa2xx_spi_init_pdata(struct platform_device *pdev) match = device_get_match_data(dev); if (match) - type = (enum pxa_ssp_type)match; + type = (uintptr_t)match; else if (is_lpss_priv) { u32 value; From patchwork Thu Aug 10 09:12:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 713157 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 283F9C001DE for ; Thu, 10 Aug 2023 09:13:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234717AbjHJJNk (ORCPT ); Thu, 10 Aug 2023 05:13:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47470 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232940AbjHJJNO (ORCPT ); Thu, 10 Aug 2023 05:13:14 -0400 Received: from mail-lf1-x12b.google.com (mail-lf1-x12b.google.com [IPv6:2a00:1450:4864:20::12b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C3FEE30E3 for ; Thu, 10 Aug 2023 02:12:55 -0700 (PDT) Received: by mail-lf1-x12b.google.com with SMTP id 2adb3069b0e04-4fe2d152f62so1010611e87.0 for ; Thu, 10 Aug 2023 02:12:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691658774; x=1692263574; 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=EFC8UwWW+iR30JPgYo5rYE8kvBFOSJM2pan/x7dG/FQ=; b=XOfnHOF8Ge3HS+SYIPZG2zjLSG/3isat/D89FvJn8O1gOqPaa5eIbissd+xIj2L2Lw WgztZ6Gyn0RxAvUIJyP9r+vpkz8eUcdurVVgvuXscBkB2iru2B/JgRLHIKcu81g3r1Bt EosbxjvmqNMnQIoIhJ+4Q362u2UxA2U97mxiLMcOwYeTgdrxAkxJ+1fbBDhCgRa4yxG5 ez7jwHywBaZ3U5a26UH8bz0vjqhEBzEqUwNlSJc5SyGwCHZjCLuL56JG+U0HPCQGeTy0 VmyygMb2w0DmosFubJM/3zPHGYcDKQ+4Dw4Jj4O0lMsVKIgKACHfMpLSlWZxvRfP0ofP mTAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691658774; x=1692263574; 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=EFC8UwWW+iR30JPgYo5rYE8kvBFOSJM2pan/x7dG/FQ=; b=IAaXeQyEI2qyTpz1gRRqDJZrHdtfrTg6kE1uwWHSqL6mEAx3AUBoiXm3PA+Ejao9Xm qSRBveDeW1whRZw23144/4aWOzZFqy9+bPXnjDBZFEaF+CIrCiaCL3Yt2ts7QTGR9iV4 zL9Utd8AsSVsik0eb7wQb2V477SYn65AyoPb09S61Dxh06ZxSrxO9C5pS4fZYvq7qyqR ZZQLrF5KxzJElJLI+TkQaHCOrR6XJq90rON67P0joxXIAc/tK79A6LWDvAZCRVy9YDOZ O9Gpp5okQeKrvGVzKXgYerubZ16NOLX+wREKiy8+j/P67FYq/GfwEKwnMayuLue8hDU6 Fw9w== X-Gm-Message-State: AOJu0YwZcN0faOFwxjcYVKbU0tfWetLL5KPZHlvhZZn2L6J933q6hVZ9 QTfw9H8VPjF1xc9IrLUwMKCCDEKf8hHAj5I+gX1Yhg== X-Google-Smtp-Source: AGHT+IFKBRECSDxdUSRf4SBuIAe9GvX6BSkSredNNZfpc6UoJ0zsZfV58pjE4WqjMdZojS0LAmA//A== X-Received: by 2002:a05:6512:3b21:b0:4fe:82c:5c8a with SMTP id f33-20020a0565123b2100b004fe082c5c8amr1540576lfv.58.1691658774124; Thu, 10 Aug 2023 02:12:54 -0700 (PDT) Received: from krzk-bin.. ([178.197.222.113]) by smtp.gmail.com with ESMTPSA id m8-20020a056402050800b0051ff2b6139esm538889edv.5.2023.08.10.02.12.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Aug 2023 02:12:53 -0700 (PDT) From: Krzysztof Kozlowski To: Sanjay R Mehta , Mark Brown , Daniel Mack , Haojian Zhuang , Robert Jarzmik , linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Andi Shyti , Krzysztof Kozlowski Subject: [PATCH net-next 3/3] spi: amd: fix Wvoid-pointer-to-enum-cast warning Date: Thu, 10 Aug 2023 11:12:47 +0200 Message-Id: <20230810091247.70149-3-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230810091247.70149-1-krzysztof.kozlowski@linaro.org> References: <20230810091247.70149-1-krzysztof.kozlowski@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-spi@vger.kernel.org 'version' is an enum, thus cast of pointer on 64-bit compile test with W=1 causes: spi-amd.c:401:21: error: cast to smaller integer type 'enum amd_spi_versions' from 'const void *' [-Werror,-Wvoid-pointer-to-enum-cast] Signed-off-by: Krzysztof Kozlowski --- drivers/spi/spi-amd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/spi/spi-amd.c b/drivers/spi/spi-amd.c index b19766571f28..8b3eabb4cb38 100644 --- a/drivers/spi/spi-amd.c +++ b/drivers/spi/spi-amd.c @@ -398,7 +398,7 @@ static int amd_spi_probe(struct platform_device *pdev) dev_dbg(dev, "io_remap_address: %p\n", amd_spi->io_remap_addr); - amd_spi->version = (enum amd_spi_versions) device_get_match_data(dev); + amd_spi->version = (uintptr_t) device_get_match_data(dev); /* Initialize the spi_master fields */ master->bus_num = 0;