Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp3043997pxb; Tue, 12 Jan 2021 05:07:34 -0800 (PST) X-Google-Smtp-Source: ABdhPJz6BcISULh/de5cslX1CGfHa6WT195hFyWTSb01N9I2Es+b4j7zvK9R1SEPYBN5raRkItaI X-Received: by 2002:a17:906:32d6:: with SMTP id k22mr3175629ejk.457.1610456854170; Tue, 12 Jan 2021 05:07:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610456854; cv=none; d=google.com; s=arc-20160816; b=g8lE3ENj2K/nnTQHVOtydjB/yOtgELQ6plULoc06wiXiq+7vmmzCY9gxk2rgixE8BY N7ZG5ULh0/UZxLd6oAtteGapxlwTV8WKpd8zIoafyClcw6aSzYL8Pn53fTJJ9vhSLw4Y TGXgEPvNmeB1zjpLxtjOL7BlyYtMCaXUDcNYUKlXvau8qdhaB9QMTCXs/QaDzcA08NWR JqiohIadp01ei390h2iv/bZGypdU4OTlIVy2aFSDQOe25PSf1gJfJkYD6W3AAUK1bft5 8jNskL74IbOQDHfOViKE/zC7rzhibsl00NS3pd4CeruBsOxcbDWDJII2rPZNthBkKO6I Y6sA== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=MbuUq4P3EHTaRZRZIMbCktw9khedoDm+hM+zJy1KsqI=; b=OHs66qbizHLKKyuPByLdhzw3GNkIHjtQ8Ua+cbS6NB4OT3l0eV5y+8gsVqaaE6bkfv qIez7YIYLaPA11brBuw5UBm0CmxIH/k0jUlUt0Nw7Z5sjzYxvgIRbn9Gdx5SynmUnH4z ViQy1wfI/Pf197mZIBblVMr4J8uqxwUcLSyRP4WG7ndELiu36/HiIrisuApSSrOj4wXP cDkdPVhPg386EyJ7PmsO8M6i1DW961+lvIb5HZ/jbbBvqA0j84B89OD82EkdLsM8U8sE 1m4HxcAYpNMgPi4B68F8XzeQG3GmbZ7Kcs0vpuj1R5bpHRF6HtFy2xG4Pt7xFzpGESYO gIyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=LhTgig3W; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cw9si1254191edb.354.2021.01.12.05.07.05; Tue, 12 Jan 2021 05:07:34 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-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=@chromium.org header.s=google header.b=LhTgig3W; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1733130AbhALMVk (ORCPT + 99 others); Tue, 12 Jan 2021 07:21:40 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37486 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727687AbhALMVk (ORCPT ); Tue, 12 Jan 2021 07:21:40 -0500 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8060BC06179F for ; Tue, 12 Jan 2021 04:20:59 -0800 (PST) Received: by mail-wm1-x330.google.com with SMTP id e25so1941656wme.0 for ; Tue, 12 Jan 2021 04:20:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=MbuUq4P3EHTaRZRZIMbCktw9khedoDm+hM+zJy1KsqI=; b=LhTgig3W3sY07dXxslzsfjFFIfbXnY40C8dWqKXdoxjaCsPK6Sxr2e7t/oPOPZPYHs 1eQoNC/fomQriaKt2PO/gTKRdDmMUUQiU7zqiqNWSzRgRVB7LXj+orqSFahMBEglKJCA NUFevB0PHOengYR/AUjkRLCQ40QEEWx7YblPk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=MbuUq4P3EHTaRZRZIMbCktw9khedoDm+hM+zJy1KsqI=; b=QQwkifg0kPOONwnSrFkpIr9+FgZ70+DGe2/au1yZ4l3cCrP0A405epOunU3rOu08rl 60W4Wt+XudFAgiaiL32ny4KBHPynF3HuV1q1yZjiPGgxDH0w5fKtsY5gGKtCgvkF5TEu OT7Ya8y96OcOaNEyS26C2q4sTkhn/u4yxeIXkZINuASvra1zmEsHmB1HX13LrfmXmeWa 0EodS4NzWgeck0V8rS6zVcTChfPaqYU4vWgNZGbfEzhJ1Iu5AuEd+uiQxMj/XMz0dRFu rQUyF2DEKWnYRe1DFYuJe7ODjzuniL+8hyvcQKqq3d3j6IfeaFHf/j+BP0xeVVVWieKa Y9aA== X-Gm-Message-State: AOAM532J5XbpHP/07BIu4j7q3ldZngxIFyFvfpjjPhyzhj3JgDCxC9Ox meOqSwReM0NCJ8wLN2k/TEQ1XA== X-Received: by 2002:a1c:7217:: with SMTP id n23mr3243366wmc.167.1610454058331; Tue, 12 Jan 2021 04:20:58 -0800 (PST) Received: from alco.lan ([80.71.134.83]) by smtp.gmail.com with ESMTPSA id w189sm3781384wmg.31.2021.01.12.04.20.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Jan 2021 04:20:57 -0800 (PST) From: Ricardo Ribalda To: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, kieran.bingham+renesas@ideasonboard.com, Ezequiel Garcia Cc: Ricardo Ribalda , Maxime Ripard , Chen-Yu Tsai Subject: [PATCH v2 6/9] media: sun4i-csi: Do not zero reserved fields Date: Tue, 12 Jan 2021 13:20:52 +0100 Message-Id: <20210112122053.10372-1-ribalda@chromium.org> X-Mailer: git-send-email 2.30.0.284.gd98b1dd5eaa7-goog MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Maxime Ripard Cc: Chen-Yu Tsai Reviewed-by: Kieran Bingham Signed-off-by: Ricardo Ribalda --- drivers/media/platform/sunxi/sun4i-csi/sun4i_v4l2.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/drivers/media/platform/sunxi/sun4i-csi/sun4i_v4l2.c b/drivers/media/platform/sunxi/sun4i-csi/sun4i_v4l2.c index 1a2f65d83a6c..4785faddf630 100644 --- a/drivers/media/platform/sunxi/sun4i-csi/sun4i_v4l2.c +++ b/drivers/media/platform/sunxi/sun4i-csi/sun4i_v4l2.c @@ -113,8 +113,6 @@ static void _sun4i_csi_try_fmt(struct sun4i_csi *csi, pix->num_planes = _fmt->num_planes; pix->pixelformat = _fmt->fourcc; - memset(pix->reserved, 0, sizeof(pix->reserved)); - /* Align the width and height on the subsampling */ width = ALIGN(pix->width, _fmt->hsub); height = ALIGN(pix->height, _fmt->vsub); @@ -131,8 +129,6 @@ static void _sun4i_csi_try_fmt(struct sun4i_csi *csi, bpl = pix->width / hsub * _fmt->bpp[i] / 8; pix->plane_fmt[i].bytesperline = bpl; pix->plane_fmt[i].sizeimage = bpl * pix->height / vsub; - memset(pix->plane_fmt[i].reserved, 0, - sizeof(pix->plane_fmt[i].reserved)); } } -- 2.30.0.284.gd98b1dd5eaa7-goog