Received: by 2002:ab2:7104:0:b0:1f7:f6c3:9cb1 with SMTP id z4csp51720lql; Tue, 7 May 2024 09:28:29 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCV9YCXIuMVFP+m1x1b9Tka9jreN6XShP4ZmzgCLs2KHl2pyKTbPKuTq2VBW8eU5uL0aBIVWrGtmuVoLp7PcMGAdaKASiqqNGJcj7hJjaA== X-Google-Smtp-Source: AGHT+IES0zuPTJrY+CSYGz+JJafeUtREctzKA5TBQZmLQpzU5FcUtCoEzP1Wl6NI8BzTQbnUH4dM X-Received: by 2002:a05:6a21:8805:b0:1af:adbf:2a16 with SMTP id adf61e73a8af0-1afc8d8ebf4mr253021637.43.1715099308963; Tue, 07 May 2024 09:28:28 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715099308; cv=pass; d=google.com; s=arc-20160816; b=ySj5F2wzBC6i/l1I5DQLpHzUX9Ql5/eYagTVInZS3yHvcPj5e5SG/9VRvGYGYiDbk7 +FWy19DPw36CBxYGMBzrvfHqC6ZInM1/kvms74IqeJTNqlf04l/nl1o9Mdee1uWF234U 6dt1fEv7/uLMw3/e3Z0+b1NHi0K++uWyTwboyA9m9fSvIB9QkhqGLzJ3JARu2OART6ql +yQssyDKWcFKm/NAshbmROaw73nCk/zw3UBT/84iXn6nKp57ny9KBt1oyR8d2G7NfqQU 0HiPhRKGsBU5CMv4AK+L5P7FjeUM3nW0t8GdVw4clyYuvsDGQHZa3ORXQvw7VWCDz0Gx jEpw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=1/P1ujR64RjpeY3CCEbW1xPPMvUuqlT7weCmbLOLgyg=; fh=DdAZSY0Tb7jjGfgBcIDdkHXtf3jTxVam3YfsMzREG3E=; b=v9fYspw8fDgcJ7NLgj/hshUY7NzPYpPoZLI0bSkHDL29Z4DXRcXaCKtAqelsWrINTw VJEyG2G+czf2YWOJm+s47HeMQNMI/2SDZoJnVsarodu4qZoA4H4QDY50QdJqI7GcgZ3+ bt0vtWiPAU87OTqSpo8LO8thxQ/cuRUB/ZadxCqmdLyOf+5um5wmNzpBwYA3e8rNmFW4 +M7FpjZCfLY0XI+3qrx3hxL5In8VmBIzu60XIFEMRKkv2JhAsKrMumecI5nftwVYD2od xSce7JJLleG0yEKEmLJD18V1tQ7MbYZxTi+QePZbbHcyj9FsBJeSU5snuBinU2iOqiZs qVIw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=XAmU4MYL; arc=pass (i=1 spf=pass spfdomain=chromium.org dkim=pass dkdomain=chromium.org dmarc=pass fromdomain=chromium.org); spf=pass (google.com: domain of linux-kernel+bounces-171802-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-171802-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id hu2-20020a056a00698200b006f44aa616c0si8803979pfb.350.2024.05.07.09.28.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 May 2024 09:28:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-171802-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=XAmU4MYL; arc=pass (i=1 spf=pass spfdomain=chromium.org dkim=pass dkdomain=chromium.org dmarc=pass fromdomain=chromium.org); spf=pass (google.com: domain of linux-kernel+bounces-171802-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-171802-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 4FC652834A2 for ; Tue, 7 May 2024 16:28:28 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7410016D4F5; Tue, 7 May 2024 16:27:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="XAmU4MYL" Received: from mail-qt1-f182.google.com (mail-qt1-f182.google.com [209.85.160.182]) (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 E1A2A16C867 for ; Tue, 7 May 2024 16:27:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.160.182 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715099235; cv=none; b=uCLDV//AMVi45nTiNU//2tupJVYJlMWCuhr19O/AKB6SXHN8TZRfVLSmvy47rjbtK2HIftDVkNuwX7yftlvE2Pd+jyBdIkePRN9IOXQMs03Esl1FqWclQvpZsoZizIO2M8Dd1UXxgnUITrXMJr+aOeGDdbOSYNxCfxhfTJWooUk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715099235; c=relaxed/simple; bh=OkrWWOrUN5GNEWioxP3gYdPUo0/0BfsqCVC0RCoziIM=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=UYsnMtiz/oi15lRYBKvkhGPzHTzdj4B3O6XslC+CLaebBiX0gU2aGsE51VRC8GP4Lhp1KaE7ym/sK3MDkaB6DyaAGSwekT+tkxGEH4ivQ2xMvT+wGv8BhauPqTaPhW7AwC6AD1LYm1XZ9q5RpP4z3jOGYqNmVc+nZDZSlE5UpJY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org; spf=pass smtp.mailfrom=chromium.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b=XAmU4MYL; arc=none smtp.client-ip=209.85.160.182 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=chromium.org Received: by mail-qt1-f182.google.com with SMTP id d75a77b69052e-43d2b4d4d3eso11665851cf.2 for ; Tue, 07 May 2024 09:27:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1715099233; x=1715704033; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=1/P1ujR64RjpeY3CCEbW1xPPMvUuqlT7weCmbLOLgyg=; b=XAmU4MYLi02oAxX+z7YpNhFUitd+z+s2/ZOhYAy6yaVetxmgXSpGURekWjjgAUa6jG VIm0RbDfmm7P0O5j9sHsPbV++h8J/7OD874thrmLJyGM9oeyexdvAe20zb52YWmfPcCe mQeE8LW6y4KVyL9iTrbV68gBhmLkSUAkRijBg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715099233; x=1715704033; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=1/P1ujR64RjpeY3CCEbW1xPPMvUuqlT7weCmbLOLgyg=; b=X1PwMNSP6OO5UIJlfPEpAKohxk+pUZ0FT4gVmvPMNckGJf5jvYh4d/2W8O+GH1gXxm KJxupZmDTdu0Pc34y88O7UD1YUmS4IWIyNsgcM5Ya7TwlvEaCiTYa0Q9S1bRT3CW6mn1 uvu/7dAuV7nQw/XlKZRuQYaS4gPR7GuzgYoqXm79xFyhwpTTMtc6A8brtvrETG0jUWM4 3ntMijwHpgn6KmaBMCDVx3y0G2uxOj84xMn62shPR07XLYZz6NjWJwtWnTu/snP1/ml+ UiApW0HVITrD837A1QEVvtYwfqDCo8+2/GZFLJ9WEWGEeE3aDL/bbv2kxBeoHdCSjekF ll9g== X-Forwarded-Encrypted: i=1; AJvYcCUV99bKRlicgFjQ2Lr2gjWTzcHwPSQsqRP9X11nKpSURP8sCuQj2IU53iVhK7EQFtA4uJD8ew2hw4gWhU5twIGcIilhyRcHcD6+SI6g X-Gm-Message-State: AOJu0YzqjRFkPI0Hfrgqa0bDjyuXznjdo5jm8xULzRgeibQM+yIhXqo4 DG1KoiP7RZISTJ+Sfpt7nVNwX4WcQCw7jjshW5CUcPYpLDaMCFo1OkRjHaDYjg== X-Received: by 2002:a05:622a:2994:b0:43c:748f:6e96 with SMTP id d75a77b69052e-43dbf622550mr1868001cf.39.1715099233022; Tue, 07 May 2024 09:27:13 -0700 (PDT) Received: from denia.c.googlers.com (114.152.245.35.bc.googleusercontent.com. [35.245.152.114]) by smtp.gmail.com with ESMTPSA id hf23-20020a05622a609700b0043d1fc9b7d9sm4160597qtb.48.2024.05.07.09.27.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 May 2024 09:27:12 -0700 (PDT) From: Ricardo Ribalda Date: Tue, 07 May 2024 16:27:09 +0000 Subject: [PATCH v2 04/18] media: dvb-frontend/mxl5xx: Use flex array for MBIN_SEGMENT_T Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240507-cocci-flexarray-v2-4-7aea262cf065@chromium.org> References: <20240507-cocci-flexarray-v2-0-7aea262cf065@chromium.org> In-Reply-To: <20240507-cocci-flexarray-v2-0-7aea262cf065@chromium.org> To: Michael Tretter , Pengutronix Kernel Team , Mauro Carvalho Chehab , Laurent Pinchart , Michal Simek , Andy Walls , Stanimir Varbanov , Vikash Garodia , Bryan O'Donoghue , Bjorn Andersson , Konrad Dybcio Cc: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, Hans Verkuil , Ricardo Ribalda X-Mailer: b4 0.12.4 Replace the older style one-element array with a flexible array member. There does not seem to be any allocation for this struct in the code, so no more code changes are required. The following cocci warning is fixed: drivers/media/dvb-frontends/mxl5xx_defs.h:182:4-8: WARNING use flexible-array member instead (https://www.kernel.org/doc/html/latest/process/deprecated.html#zero-length-and-one-element-arrays) Signed-off-by: Ricardo Ribalda --- drivers/media/dvb-frontends/mxl5xx_defs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/dvb-frontends/mxl5xx_defs.h b/drivers/media/dvb-frontends/mxl5xx_defs.h index 3c5d75ed8fea..512ec979f96f 100644 --- a/drivers/media/dvb-frontends/mxl5xx_defs.h +++ b/drivers/media/dvb-frontends/mxl5xx_defs.h @@ -179,7 +179,7 @@ struct MBIN_SEGMENT_HEADER_T { struct MBIN_SEGMENT_T { struct MBIN_SEGMENT_HEADER_T header; - u8 data[1]; + u8 data[]; }; enum MXL_CMD_TYPE_E { MXL_CMD_WRITE = 0, MXL_CMD_READ }; -- 2.45.0.rc1.225.g2a3ae87e7f-goog