From patchwork Thu May 20 09:23:18 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 443216 Delivered-To: patch@linaro.org Received: by 2002:a02:7a1b:0:0:0:0:0 with SMTP id a27csp2165006jac; Thu, 20 May 2021 03:42:35 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwSl16Lngh8ng67QbmjsGWEbUFu3UMRtA/MxHEZRWQ0dFPKBsc/uqpZcA0tnL4H1opmZXrA X-Received: by 2002:aa7:cfcd:: with SMTP id r13mr4346323edy.177.1621507354953; Thu, 20 May 2021 03:42:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621507354; cv=none; d=google.com; s=arc-20160816; b=sCKVRIVlJ+81wmHlv17c7nPcSP7fqO02AyzEz9qydMYrNZuXi7xyWUmUidJiOh3h2s tCRS3OR0SKza6mozLlJqrgiBgxaRYmMrKfjav+iligHyqyBv3IiA9Xd0Coa5rvh5Dfle zi5HHr7u711hkO0IgjRr6/SGqGRMMVAzMy3UzmefoiVte6uU4NMV6r0/IJsF1YIc1Cbm UVEebF3OieKhD8a7vLQCq7yXGmqLnU5RerkYNva9CA+btAtKjdhtauqGNZbaKRHEfUu9 gp2V5/dJUPCr8EEHAcQ2DDnV7JU94rp4MDy8WvXL6rrX8VkvE6+1FZQSTCKdcTh/C4c8 flzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=DpHowD0k0EHpFJ1pWaXIgsH4VXmxbk8VK3HT5zgDUdY=; b=IN0QTnFyr3HVJhYImGmQO4bP+c1kedT1dPbF98IO+ZTbYf7M0yDpGMMH040wftGI9j W6IPzEGdfdYdrSnjAShC+LtrGU80hD9lgd5QLIYyqnNj6UF4QfvX6PVeZWksi46uEAoP XmMdiYADxLLhXF44H+wpeIKTAqkZYGkowAxm0bjy7hw3xZaqCKKLeaWPqKubkX/Zi6kJ zdo3bI4LwOcuVP1//pNpXro3Zt76gCD3JeTY196P02k2OmAUQbV4YdeICiS3vg2S/O51 IfA1zFeyJj1P/MnA0NOUM8YKeP45jthP032pERTX5UwiqIuj3OQJpqOyLjZ7p5MLp7qN 0Qug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=tj6hCVcG; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t16si2432086edi.299.2021.05.20.03.42.34; Thu, 20 May 2021 03:42:34 -0700 (PDT) Received-SPF: pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=tj6hCVcG; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237586AbhETKnx (ORCPT + 12 others); Thu, 20 May 2021 06:43:53 -0400 Received: from mail.kernel.org ([198.145.29.99]:44704 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237580AbhETKlq (ORCPT ); Thu, 20 May 2021 06:41:46 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id A0ED461C8D; Thu, 20 May 2021 09:56:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1621504574; bh=FQzU1ywP14McHhXd/bP7dyfK9IQrVfQ81ynkrpqJyN8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=tj6hCVcGqS4rRw3GkGa1xy4v5TZXysVSUiaYzLsTADj3q8PR6e7IdWqoZeUbnfRxA voHiss2LLu3rLGQDxGvbN7hYdQV3kAdKjAApj48JT/DJ869+3upFu5kTME7W8a22Tu Wz8YDo+z2JQdRbH2Yj4PV2PlNLnigMHTVhrP6+pI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Arnd Bergmann , "David S. Miller" Subject: [PATCH 4.14 306/323] isdn: capi: fix mismatched prototypes Date: Thu, 20 May 2021 11:23:18 +0200 Message-Id: <20210520092130.726592263@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210520092120.115153432@linuxfoundation.org> References: <20210520092120.115153432@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Arnd Bergmann commit 5ee7d4c7fbc9d3119a20b1c77d34003d1f82ac26 upstream. gcc-11 complains about a prototype declaration that is different from the function definition: drivers/isdn/capi/kcapi.c:724:44: error: argument 2 of type ‘u8 *’ {aka ‘unsigned char *’} declared as a pointer [-Werror=array-parameter=] 724 | u16 capi20_get_manufacturer(u32 contr, u8 *buf) | ~~~~^~~ In file included from drivers/isdn/capi/kcapi.c:13: drivers/isdn/capi/kcapi.h:62:43: note: previously declared as an array ‘u8[64]’ {aka ‘unsigned char[64]’} 62 | u16 capi20_get_manufacturer(u32 contr, u8 buf[CAPI_MANUFACTURER_LEN]); | ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/isdn/capi/kcapi.c:790:38: error: argument 2 of type ‘u8 *’ {aka ‘unsigned char *’} declared as a pointer [-Werror=array-parameter=] 790 | u16 capi20_get_serial(u32 contr, u8 *serial) | ~~~~^~~~~~ In file included from drivers/isdn/capi/kcapi.c:13: drivers/isdn/capi/kcapi.h:64:37: note: previously declared as an array ‘u8[8]’ {aka ‘unsigned char[8]’} 64 | u16 capi20_get_serial(u32 contr, u8 serial[CAPI_SERIAL_LEN]); | ~~~^~~~~~~~~~~~~~~~~~~~~~~ Change the definition to make them match. Signed-off-by: Arnd Bergmann Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- drivers/isdn/capi/kcapi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/isdn/capi/kcapi.c +++ b/drivers/isdn/capi/kcapi.c @@ -845,7 +845,7 @@ EXPORT_SYMBOL(capi20_put_message); * Return value: CAPI result code */ -u16 capi20_get_manufacturer(u32 contr, u8 *buf) +u16 capi20_get_manufacturer(u32 contr, u8 buf[CAPI_MANUFACTURER_LEN]) { struct capi_ctr *ctr; u16 ret; @@ -915,7 +915,7 @@ EXPORT_SYMBOL(capi20_get_version); * Return value: CAPI result code */ -u16 capi20_get_serial(u32 contr, u8 *serial) +u16 capi20_get_serial(u32 contr, u8 serial[CAPI_SERIAL_LEN]) { struct capi_ctr *ctr; u16 ret;