From patchwork Fri Oct 18 07:52:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Harvey Yang X-Patchwork-Id: 21664 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id EE1B8C32FE for ; Fri, 18 Oct 2024 07:52:52 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id BD2996538B; Fri, 18 Oct 2024 09:52:51 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="b57/bcxY"; dkim-atps=neutral Received: from mail-pl1-x632.google.com (mail-pl1-x632.google.com [IPv6:2607:f8b0:4864:20::632]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 4C67A65379 for ; Fri, 18 Oct 2024 09:52:50 +0200 (CEST) Received: by mail-pl1-x632.google.com with SMTP id d9443c01a7336-20cdb889222so19004105ad.3 for ; Fri, 18 Oct 2024 00:52:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1729237968; x=1729842768; darn=lists.libcamera.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=ZwebKJfAGBPJhOfJWOtRSD7ZIUDGMzFxv9NXGtefBUM=; b=b57/bcxYemfVb7FihuWqZeWvrprSG332YxQvuVxCIhZqXAyzEIXu34mD7gzlJVJGAr rw19gpSl6jd21o/Fxe8d8rkq5p/9lv6rrAnmasHPAxa1AEXowLbomShQBdMbke35r/fk yzYOZJxtXo1Ixat2pkzGB5U52amt6BrQdijrQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729237968; x=1729842768; 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=ZwebKJfAGBPJhOfJWOtRSD7ZIUDGMzFxv9NXGtefBUM=; b=p70G3bSUsF3UptPJOJ7uCDVWJwzUUhUprub5ju2jNODfIrvIhBCPpYZo1Ai8YzpP3Y ppBEzMzZoE0JDJeYLRkMHOGKrlB8jF2MIuZB+qEiQIHoYC+6Ps6dhaafH5r9rMQPU6vv Whe9wEph5cjN0Aas/n3ZHLi5kG3c2oQa2FbK/HUZlEEhlM1EFOcxrGQiohhqTNoih2Sf wnBnsQm6TN2XekCyCy17UREPZtvkOCncSeKhGhxjC3BH9YhPQ3DQg7lBccxM2vdIGU7u FEkSA/epmKjMsuQqhQNWF++44X4mw2mLbQKHwlJO/V5C8uJxtySSbXa2nU2nJl5SpSVJ FJwQ== X-Gm-Message-State: AOJu0YydV6ylWOetxNC9luIWyjpgIgatkjoFi8zeyKLx88HVMXnjGFv0 lKgKaqNE43WaFO2v7Gd5OG4mfsfMD+0AiXQRoCgH1WU2vexu/zhpn4+BQyhPNW9s6V8G2p5RyL8 = X-Google-Smtp-Source: AGHT+IG+KQMhmtW1qqnshCSHfYOUYKWhKLT9CCXYfhZm6gsC8H6bXkd5iAE3R9Val7kGRjOT6HgjKA== X-Received: by 2002:a17:903:41cd:b0:20c:675d:923d with SMTP id d9443c01a7336-20e5a8f23cfmr19354705ad.39.1729237967971; Fri, 18 Oct 2024 00:52:47 -0700 (PDT) Received: from chenghaoyang-low.c.googlers.com.com (199.211.81.34.bc.googleusercontent.com. [34.81.211.199]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-20e5a71eab2sm7453635ad.40.2024.10.18.00.52.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 18 Oct 2024 00:52:47 -0700 (PDT) From: Harvey Yang To: libcamera-devel@lists.libcamera.org Cc: Xing-Gu Chen , Harvey Yang Subject: [PATCH] libcamera: mtkisp7: Change ipa_control_value_entry.count to 32 bits Date: Fri, 18 Oct 2024 07:52:37 +0000 Message-ID: <20241018075242.1143876-1-chenghaoyang@chromium.org> X-Mailer: git-send-email 2.47.0.rc1.288.g06298d1525-goog MIME-Version: 1.0 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" From: Xing-Gu Chen Change ipa_control_value_entry.count to uint32_t because the element count of JpegApplicationSegmentContent is bigger than 65536. Signed-off-by: Xing-Gu Chen Co-developed-by: Harvey Yang Signed-off-by: Harvey Yang --- include/libcamera/ipa/ipa_controls.h | 2 +- src/libcamera/ipa_controls.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/libcamera/ipa/ipa_controls.h b/include/libcamera/ipa/ipa_controls.h index 5fd13394f..7a8051695 100644 --- a/include/libcamera/ipa/ipa_controls.h +++ b/include/libcamera/ipa/ipa_controls.h @@ -37,7 +37,7 @@ struct ipa_control_value_entry { uint32_t id; uint8_t type; uint8_t is_array; - uint16_t count; + uint32_t count; uint32_t offset; uint32_t padding[1]; }; diff --git a/src/libcamera/ipa_controls.cpp b/src/libcamera/ipa_controls.cpp index 9420c889f..a1ccc7d61 100644 --- a/src/libcamera/ipa_controls.cpp +++ b/src/libcamera/ipa_controls.cpp @@ -207,7 +207,7 @@ static_assert(sizeof(ipa_controls_header) == 32, * Padding bytes (shall be set to 0) */ -static_assert(sizeof(ipa_control_value_entry) == 16, +static_assert(sizeof(ipa_control_value_entry) == 20, "Invalid ABI size change for struct ipa_control_value_entry"); /**