From patchwork Thu Aug 10 08:50:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 13349050 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 346A1C001DE for ; Thu, 10 Aug 2023 08:51:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=uHjxMStka8n/tlybAX1//EdrAVbR78P3UIBar+ndMyo=; b=vHZBpywABH6egP eFzg6pTw6mCeOqaJ/khLA0F+BedEnFLgBGjU4FalqN33CGMO55TSMi/6FxJ9lK40yD/nrIyww5ig0 xo1WHdsoYcbGAlAdLasGa6nS9dfol0/FlfID1NQL9U9/5fMIAKk+gFiX4lHUgeRJPfeubJhJETod6 kPGccA5c+8Z0ZgO6mcoI0rh1UIwAT7hzQlsLV/TcCjFmXaag9tQT1FlwdWWfW1PIxTeJ8UaYW4XH7 y+IllQy2+6Yrl4uZ8LGXYMTe45OwbYb1myVh33Gh4gBWA3wPWhg/kfdJOQJdyGf0Sxo0Lof3tAyfY wTop5UWDtwSLxeObUUAA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qU1Nb-006uDT-0g; Thu, 10 Aug 2023 08:50:51 +0000 Received: from mail-wr1-x42c.google.com ([2a00:1450:4864:20::42c]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qU1NY-006uCk-1F for linux-arm-kernel@lists.infradead.org; Thu, 10 Aug 2023 08:50:49 +0000 Received: by mail-wr1-x42c.google.com with SMTP id ffacd0b85a97d-31781e15a0cso634682f8f.3 for ; Thu, 10 Aug 2023 01:50:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691657446; x=1692262246; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=zUA6Uop1470tUJbDViYaX4LRHpvZYJIyke3HCwbN6+o=; b=o2dv9R0JA3ZxL9ing7at6nqKjTLilmMT0IQRbfsOpS8nBL9yjoITmy2fRO+my3ZMRu s+5a+R+fxQDERaGpBHUyUsDhTzQNOaKC1pNAuNA+P2i1Xra3XgkKLHODmJEyEABz5lIc TXXVcRuElWHjZU30tkr19+P3PI+9FiD2x5wOPq0sKGOuxqcPPX5lDd0IdorEgvYuO69p y+gy90/0W/HJqjb4yqVFS9X0OzWyl7T/ieaeEWoX9DIa9bDckj/75hVKwniRSqhnIkHo Z/2LKe7ax2ZNTZUzXO+Wr1qNfv94J30qMRMfgJb1ULBW+y9rLXuhZHfbeeMvy2Gto9tr s/iA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691657446; x=1692262246; 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=zUA6Uop1470tUJbDViYaX4LRHpvZYJIyke3HCwbN6+o=; b=k1LVu5MNKgKdUe1BaBOb1io5vn6bDVH07mjIyR+/+Z0FPG061kp64/UNLLfO2XZT1c lGzj7M54r8I8/iIBOnzau7jHmRVlSfZkqRvfpbeqeIxwYdYsMJjm9i/RmixESXpuJiYH 0yiKpqO3pKPVSf0Pj/VoZolGbxJViEroPK8V3OMYcnJC8Y/UcUes+frFnvZY3uVai/P4 OXeaecQ6GbIizymY4q9itRrX8uNZcyfDJIp4yhXgKi0UAfBxFU4UdRKf3LdhZru/wK1T jSAoB67mrWtNXc0ou72hVWfUGePlZLhZMwspIa+n9/aMTy8rMg0rcSuvCbih9xjVVJXW O83g== X-Gm-Message-State: AOJu0Yy/F7DOjd99RzwdiWSRZNAFuC6Y1x55H0E+2nDFr7Kj+M+ZJoqq ip94502dxbKSLwrbDWwqU+Zc5w== X-Google-Smtp-Source: AGHT+IFb8oMsS0S9gnDkp6ZtkyHaO2DhrB8218z+QoY+VxqPi+V1z6jMgz1d8pK94alrz+7qUBOzLQ== X-Received: by 2002:adf:f011:0:b0:317:43e0:3f47 with SMTP id j17-20020adff011000000b0031743e03f47mr1605618wro.36.1691657445994; Thu, 10 Aug 2023 01:50:45 -0700 (PDT) Received: from krzk-bin.. ([178.197.222.113]) by smtp.gmail.com with ESMTPSA id q11-20020adfcd8b000000b003180155493esm1395013wrj.67.2023.08.10.01.50.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Aug 2023 01:50:45 -0700 (PDT) From: Krzysztof Kozlowski To: Greg Kroah-Hartman , Jiri Slaby , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Krzysztof Kozlowski , Andi Shyti Subject: [PATCH] serial: mxs-uart: fix Wvoid-pointer-to-enum-cast warning Date: Thu, 10 Aug 2023 10:50:42 +0200 Message-Id: <20230810085042.39252-1-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230810_015048_426480_B888F299 X-CRM114-Status: GOOD ( 12.13 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org `devtype` is enum, thus cast of pointer on 64-bit compile test with W=1 causes: mxs-auart.c:1598:15: error: cast to smaller integer type 'enum mxs_auart_type' from 'const void *' [-Werror,-Wvoid-pointer-to-enum-cast] Cc: Andi Shyti Signed-off-by: Krzysztof Kozlowski --- drivers/tty/serial/mxs-auart.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/tty/serial/mxs-auart.c b/drivers/tty/serial/mxs-auart.c index 8eeecf8ad359..a9b32722b049 100644 --- a/drivers/tty/serial/mxs-auart.c +++ b/drivers/tty/serial/mxs-auart.c @@ -1595,7 +1595,7 @@ static int mxs_auart_probe(struct platform_device *pdev) return -EINVAL; } - s->devtype = (enum mxs_auart_type)of_device_get_match_data(&pdev->dev); + s->devtype = (uintptr_t)of_device_get_match_data(&pdev->dev); ret = mxs_get_clks(s, pdev); if (ret)