[{"id":30839,"web_url":"https://patchwork.libcamera.org/comment/30839/","msgid":"<172371549845.2731480.17326395158292123568@ping.linuxembedded.co.uk>","date":"2024-08-15T09:51:38","subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Hi Maarten,\n\nThank you for highlighting this. I'm curious that it hasn't come up in\nour builds yet! What version of clang are you using?\n\nQuoting Maarten Lankhorst (2024-08-15 10:37:15)\n> I was getting the following error in clang:\n> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: error: using integer absolute value function 'abs' when argument is of floating point type [-Werror,-Wabsolute-value]\n>         if (abs(denominator) > eps) {\n>             ^\n> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: note: use function 'std::abs' instead\n\nIs there a preference against the recommended std::abs?\n\n>         if (abs(denominator) > eps) {\n>             ^~~\n>             std::abs\n> \n> Signed-off-by: Maarten Lankhorst <dev@lankhorst.se>\n> ---\n>  src/ipa/rpi/controller/rpi/awb.cpp | 2 +-\n>  1 file changed, 1 insertion(+), 1 deletion(-)\n> \n> diff --git a/src/ipa/rpi/controller/rpi/awb.cpp b/src/ipa/rpi/controller/rpi/awb.cpp\n> index f45525bc..c5750c84 100644\n> --- a/src/ipa/rpi/controller/rpi/awb.cpp\n> +++ b/src/ipa/rpi/controller/rpi/awb.cpp\n> @@ -505,7 +505,7 @@ static double interpolateQuadatric(ipa::Pwl::Point const &a, ipa::Pwl::Point con\n>         const double eps = 1e-3;\n>         ipa::Pwl::Point ca = c - a, ba = b - a;\n>         double denominator = 2 * (ba.y() * ca.x() - ca.y() * ba.x());\n> -       if (abs(denominator) > eps) {\n> +       if (fabs(denominator) > eps) {\n>                 double numerator = ba.y() * ca.x() * ca.x() - ca.y() * ba.x() * ba.x();\n>                 double result = numerator / denominator + a.x();\n>                 return std::max(a.x(), std::min(c.x(), result));\n> -- \n> 2.39.2\n>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 06DCDBDB13\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 15 Aug 2024 09:51:53 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 1407E633BD;\n\tThu, 15 Aug 2024 11:51:52 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 19CD063393\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 15 Aug 2024 11:51:42 +0200 (CEST)","from pendragon.ideasonboard.com\n\t(cpc89244-aztw30-2-0-cust6594.18-1.cable.virginm.net [86.31.185.195])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 86EA6827;\n\tThu, 15 Aug 2024 11:50:43 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"ZUWrI/4G\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1723715443;\n\tbh=cOhqOokue2D2FqirQ6EgmQ6HXAmqJ2nF71zv+Qmdq9M=;\n\th=In-Reply-To:References:Subject:From:Cc:To:Date:From;\n\tb=ZUWrI/4GUQgXgYct9kAo7I1MtqSFqloMRW+47rpJ0486oCI27vuSNQyDnBw1mMvHU\n\tpXywMcJ85579C/FXdEmleotV5jsWKNPe+mk9i9pJtnZzDu8pgOW4ZkYywb2dSHGS13\n\tx4LzqBuWSJgcz0HKdyItwWDDqm3UhANPF27BcfBY=","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20240815093715.165305-1-dev@lankhorst.se>","References":"<20240815093715.165305-1-dev@lankhorst.se>","Subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"Maarten Lankhorst <dev@lankhorst.se>","To":"Maarten Lankhorst <dev@lankhorst.se>, libcamera-devel@lists.libcamera.org","Date":"Thu, 15 Aug 2024 10:51:38 +0100","Message-ID":"<172371549845.2731480.17326395158292123568@ping.linuxembedded.co.uk>","User-Agent":"alot/0.10","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":30846,"web_url":"https://patchwork.libcamera.org/comment/30846/","msgid":"<20240815214959.GA23911@pendragon.ideasonboard.com>","date":"2024-08-15T21:49:59","subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"On Thu, Aug 15, 2024 at 10:51:38AM +0100, Kieran Bingham wrote:\n> Hi Maarten,\n> \n> Thank you for highlighting this. I'm curious that it hasn't come up in\n> our builds yet! What version of clang are you using?\n> \n> Quoting Maarten Lankhorst (2024-08-15 10:37:15)\n> > I was getting the following error in clang:\n> > ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: error: using integer absolute value function 'abs' when argument is of floating point type [-Werror,-Wabsolute-value]\n> >         if (abs(denominator) > eps) {\n> >             ^\n> > ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: note: use function 'std::abs' instead\n> \n> Is there a preference against the recommended std::abs?\n\nDocumentation/coding-style.rst states\n\n  Usage of the C compatibility headers is preferred, except for the\n  math.h header. Where math.h defines separate functions for different\n  argument types (e.g. abs(int), labs(long int), fabs(double) and\n  fabsf(float)) and requires the developer to pick the right function,\n  cmath defines overloaded functions (std::abs(int), std::abs(long int),\n  std::abs(double) and std::abs(float) to let the compiler select the\n  right function. This avoids potential errors such as calling abs(int)\n  with a float argument, performing an unwanted implicit integer\n  conversion. For this reason, cmath is preferred over math.h.\n\nThere's also a set of calls to abs() abd fabs() in\nsrc/ipa/rpi/controller/rpi/alsc.cpp which should be replaced by\nstd::abs().\n\nMaarten, would you like to submit a new version that addresses both ?\n\n> >         if (abs(denominator) > eps) {\n> >             ^~~\n> >             std::abs\n> > \n> > Signed-off-by: Maarten Lankhorst <dev@lankhorst.se>\n> > ---\n> >  src/ipa/rpi/controller/rpi/awb.cpp | 2 +-\n> >  1 file changed, 1 insertion(+), 1 deletion(-)\n> > \n> > diff --git a/src/ipa/rpi/controller/rpi/awb.cpp b/src/ipa/rpi/controller/rpi/awb.cpp\n> > index f45525bc..c5750c84 100644\n> > --- a/src/ipa/rpi/controller/rpi/awb.cpp\n> > +++ b/src/ipa/rpi/controller/rpi/awb.cpp\n> > @@ -505,7 +505,7 @@ static double interpolateQuadatric(ipa::Pwl::Point const &a, ipa::Pwl::Point con\n> >         const double eps = 1e-3;\n> >         ipa::Pwl::Point ca = c - a, ba = b - a;\n> >         double denominator = 2 * (ba.y() * ca.x() - ca.y() * ba.x());\n> > -       if (abs(denominator) > eps) {\n> > +       if (fabs(denominator) > eps) {\n> >                 double numerator = ba.y() * ca.x() * ca.x() - ca.y() * ba.x() * ba.x();\n> >                 double result = numerator / denominator + a.x();\n> >                 return std::max(a.x(), std::min(c.x(), result));","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 27F2BBDB13\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 15 Aug 2024 21:50:27 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id CF0D6633B4;\n\tThu, 15 Aug 2024 23:50:26 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 8694863369\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 15 Aug 2024 23:50:25 +0200 (CEST)","from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 93CB9827;\n\tThu, 15 Aug 2024 23:49:26 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"ENHKGV4O\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1723758566;\n\tbh=Jeg7yKuX9aaMgmgslyX+s+Hs+kr1H4ooEMq72+YtR2g=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=ENHKGV4O0/AJg6aL+3EI9X/pzFtKwiqnkVvOf70Deujo46QRTklmbfZdiFz6i0wgZ\n\tLvE5T+40VZ6mC6BGX7d5eMyMtaZDK+ygiyFCg7oBQJKuirLo625NdYvuJXI0uT1Wi8\n\tt1ucMjk+932NwutLql5/Vd2CKY5G1WkjNifZ3N5k=","Date":"Fri, 16 Aug 2024 00:49:59 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"Maarten Lankhorst <dev@lankhorst.se>, libcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","Message-ID":"<20240815214959.GA23911@pendragon.ideasonboard.com>","References":"<20240815093715.165305-1-dev@lankhorst.se>\n\t<172371549845.2731480.17326395158292123568@ping.linuxembedded.co.uk>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<172371549845.2731480.17326395158292123568@ping.linuxembedded.co.uk>","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":30853,"web_url":"https://patchwork.libcamera.org/comment/30853/","msgid":"<87a5hcy49u.fsf@redhat.com>","date":"2024-08-16T13:40:45","subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","submitter":{"id":177,"url":"https://patchwork.libcamera.org/api/people/177/","name":"Milan Zamazal","email":"mzamazal@redhat.com"},"content":"Kieran Bingham <kieran.bingham@ideasonboard.com> writes:\n\n> Hi Maarten,\n>\n> Thank you for highlighting this. I'm curious that it hasn't come up in\n> our builds yet! What version of clang are you using?\n\nIt happens to me too, with clang 18.1.6 on Fedora 40.\n\n> Quoting Maarten Lankhorst (2024-08-15 10:37:15)\n>> I was getting the following error in clang:\n>> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: error: using integer absolute value function 'abs' when argument is of floating point type [-Werror,-Wabsolute-value]\n>>         if (abs(denominator) > eps) {\n>>             ^\n>> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: note: use function 'std::abs' instead\n>\n> Is there a preference against the recommended std::abs?\n>\n>>         if (abs(denominator) > eps) {\n>>             ^~~\n>>             std::abs\n>> \n>> Signed-off-by: Maarten Lankhorst <dev@lankhorst.se>\n>> ---\n>>  src/ipa/rpi/controller/rpi/awb.cpp | 2 +-\n>>  1 file changed, 1 insertion(+), 1 deletion(-)\n>> \n>> diff --git a/src/ipa/rpi/controller/rpi/awb.cpp b/src/ipa/rpi/controller/rpi/awb.cpp\n>> index f45525bc..c5750c84 100644\n>> --- a/src/ipa/rpi/controller/rpi/awb.cpp\n>> +++ b/src/ipa/rpi/controller/rpi/awb.cpp\n>> @@ -505,7 +505,7 @@ static double interpolateQuadatric(ipa::Pwl::Point const &a, ipa::Pwl::Point con\n>>         const double eps = 1e-3;\n>>         ipa::Pwl::Point ca = c - a, ba = b - a;\n>>         double denominator = 2 * (ba.y() * ca.x() - ca.y() * ba.x());\n>> -       if (abs(denominator) > eps) {\n>> +       if (fabs(denominator) > eps) {\n>>                 double numerator = ba.y() * ca.x() * ca.x() - ca.y() * ba.x() * ba.x();\n>>                 double result = numerator / denominator + a.x();\n>>                 return std::max(a.x(), std::min(c.x(), result));\n>> -- \n>> 2.39.2\n>>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id DE72CC323E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 16 Aug 2024 13:40:54 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id C5567633BD;\n\tFri, 16 Aug 2024 15:40:53 +0200 (CEST)","from us-smtp-delivery-124.mimecast.com\n\t(us-smtp-delivery-124.mimecast.com [170.10.133.124])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 0AFDB633B2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 16 Aug 2024 15:40:51 +0200 (CEST)","from mail-wr1-f69.google.com (mail-wr1-f69.google.com\n\t[209.85.221.69]) by relay.mimecast.com with ESMTP with STARTTLS\n\t(version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id\n\tus-mta-464-6GYoiaAINYGRPeZmaFp7Qw-1; Fri, 16 Aug 2024 09:40:49 -0400","by mail-wr1-f69.google.com with SMTP id\n\tffacd0b85a97d-371914b5caaso524962f8f.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 16 Aug 2024 06:40:49 -0700 (PDT)","from nuthatch (ip-77-48-47-2.net.vodafone.cz. [77.48.47.2])\n\tby smtp.gmail.com with ESMTPSA id\n\tffacd0b85a97d-37189849c87sm3696157f8f.46.2024.08.16.06.40.46\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tFri, 16 Aug 2024 06:40:46 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=redhat.com header.i=@redhat.com\n\theader.b=\"ADTkxaY6\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n\ts=mimecast20190719; t=1723815651;\n\th=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n\tto:to:cc:cc:mime-version:mime-version:content-type:content-type:\n\tin-reply-to:in-reply-to:references:references;\n\tbh=rSWTtSsNg7l8FNuujka4YZ1KG6VejqDhuASQ5T3lp28=;\n\tb=ADTkxaY6y0wzkWvn62X6dHPvO2SORwt6gcmTWOS1xZQVJuAh2yPwmimbdTeVbZbs8mlyFL\n\t03aNdL0mYwW3Jce5zxyYWlAcd6r45eaGrVEEHenuAvNwqM8PhOoKSp+nIolJV7ghYNtKka\n\ty2AHNfRCBBO4vWg2/HRzMTabU9urxQ8=","X-MC-Unique":"6GYoiaAINYGRPeZmaFp7Qw-1","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1723815648; x=1724420448;\n\th=mime-version:user-agent:message-id:date:references:in-reply-to\n\t:subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date\n\t:message-id:reply-to;\n\tbh=rSWTtSsNg7l8FNuujka4YZ1KG6VejqDhuASQ5T3lp28=;\n\tb=KsfaWnSs4R6Hz1cBuxkoeAe4x3+I79NdrhnpO0AVGdLN/V0SAzQJzXVfNWJ1SG5/m4\n\tpzgPk9O5UFp3jg+2Q7isqR+hHdTETUVY1+FBwmC8vNCd95SRY6JsSR99oZ9ZdPOCnLKF\n\tgvoYsX2mfvgtqYMRabsvLm1SutcIKGDXV2QwTE5M7ASPl3ksAseCtsO6jZf58txJmEK+\n\tvj48MfUl5rvtLMW6iAD1avMW8bk6nLPvWlfxb5n/hFeS4YI3MuZ6h4HG+eJpBLZK+tTI\n\t9u/SPZX/tDkXjhsTQrKYieU6icVGHr9q4fPGUBdPWw0OXvFY+jNn1Tb5QkLF+wvbIMR5\n\t8z3A==","X-Forwarded-Encrypted":"i=1;\n\tAJvYcCWA+EE3h+qtyrS5hZH5FR4uwBg5f5FA5ymdBwTAk5TLs7zEb9LFaLCMvAJm7Atwb8a0JyGeOOr7CWXTpKcVXBpxa1xuJzv/2dIu3vMCEItHLzzwDA==","X-Gm-Message-State":"AOJu0YyEbxhwoMthg/hPgkCGLV8nslzjcxKiLidHO+GuhMw8IvVuxnR3\n\t7Gg3M68u5mnjff0y7pRWGTjBHEXCPeWN5BB9blH2gF9dFBk5NVk5ionmP7CCvpslVVmgEEfX4HS\n\tI4zpbWjcOjs4Li3bVRv+dDd4Q25KJ0yXor0Fsu34IYg10pgYhklBt5Tsy7YRKNi1FsWxKbWL01o\n\tvgtoqRY2bPtamIyhbnuC6RvWZHS5YJmbDdWoecbOvxwvOOhNqGmby2KCA=","X-Received":["by 2002:adf:f70d:0:b0:371:8bc8:ad5b with SMTP id\n\tffacd0b85a97d-37194696ce6mr1980005f8f.60.1723815648000; \n\tFri, 16 Aug 2024 06:40:48 -0700 (PDT)","by 2002:adf:f70d:0:b0:371:8bc8:ad5b with SMTP id\n\tffacd0b85a97d-37194696ce6mr1979976f8f.60.1723815647380; \n\tFri, 16 Aug 2024 06:40:47 -0700 (PDT)"],"X-Google-Smtp-Source":"AGHT+IEkOBwUfUCWGYLAeZACc7yzhTep6DRMo+PYbr3PmdBHLUstz10RWrNsXbx19mg3Kr4dYip8qA==","From":"Milan Zamazal <mzamazal@redhat.com>","To":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"Maarten Lankhorst <dev@lankhorst.se>, libcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","In-Reply-To":"<172371549845.2731480.17326395158292123568@ping.linuxembedded.co.uk>\n\t(Kieran Bingham's message of \"Thu, 15 Aug 2024 10:51:38 +0100\")","References":"<20240815093715.165305-1-dev@lankhorst.se>\n\t<172371549845.2731480.17326395158292123568@ping.linuxembedded.co.uk>","Date":"Fri, 16 Aug 2024 15:40:45 +0200","Message-ID":"<87a5hcy49u.fsf@redhat.com>","User-Agent":"Gnus/5.13 (Gnus v5.13)","MIME-Version":"1.0","X-Mimecast-Spam-Score":"0","X-Mimecast-Originator":"redhat.com","Content-Type":"text/plain","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":30854,"web_url":"https://patchwork.libcamera.org/comment/30854/","msgid":"<20240816140409.GB19657@pendragon.ideasonboard.com>","date":"2024-08-16T14:04:09","subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"On Fri, Aug 16, 2024 at 03:40:45PM +0200, Milan Zamazal wrote:\n> Kieran Bingham <kieran.bingham@ideasonboard.com> writes:\n> \n> > Hi Maarten,\n> >\n> > Thank you for highlighting this. I'm curious that it hasn't come up in\n> > our builds yet! What version of clang are you using?\n> \n> It happens to me too, with clang 18.1.6 on Fedora 40.\n\nI'm very surprised, I tested with clang 18.1.8 locally and didn't see\nany error. I would have fixed it already otherwise :-)\n\n> > Quoting Maarten Lankhorst (2024-08-15 10:37:15)\n> >> I was getting the following error in clang:\n> >> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: error: using integer absolute value function 'abs' when argument is of floating point type [-Werror,-Wabsolute-value]\n> >>         if (abs(denominator) > eps) {\n> >>             ^\n> >> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: note: use function 'std::abs' instead\n> >\n> > Is there a preference against the recommended std::abs?\n> >\n> >>         if (abs(denominator) > eps) {\n> >>             ^~~\n> >>             std::abs\n> >> \n> >> Signed-off-by: Maarten Lankhorst <dev@lankhorst.se>\n> >> ---\n> >>  src/ipa/rpi/controller/rpi/awb.cpp | 2 +-\n> >>  1 file changed, 1 insertion(+), 1 deletion(-)\n> >> \n> >> diff --git a/src/ipa/rpi/controller/rpi/awb.cpp b/src/ipa/rpi/controller/rpi/awb.cpp\n> >> index f45525bc..c5750c84 100644\n> >> --- a/src/ipa/rpi/controller/rpi/awb.cpp\n> >> +++ b/src/ipa/rpi/controller/rpi/awb.cpp\n> >> @@ -505,7 +505,7 @@ static double interpolateQuadatric(ipa::Pwl::Point const &a, ipa::Pwl::Point con\n> >>         const double eps = 1e-3;\n> >>         ipa::Pwl::Point ca = c - a, ba = b - a;\n> >>         double denominator = 2 * (ba.y() * ca.x() - ca.y() * ba.x());\n> >> -       if (abs(denominator) > eps) {\n> >> +       if (fabs(denominator) > eps) {\n> >>                 double numerator = ba.y() * ca.x() * ca.x() - ca.y() * ba.x() * ba.x();\n> >>                 double result = numerator / denominator + a.x();\n> >>                 return std::max(a.x(), std::min(c.x(), result));","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 3DDFFBDB13\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 16 Aug 2024 14:04:41 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 37291633B2;\n\tFri, 16 Aug 2024 16:04:40 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 1DB44633B2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 16 Aug 2024 16:04:38 +0200 (CEST)","from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 767F173E;\n\tFri, 16 Aug 2024 16:03:38 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"dk27sjs1\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1723817018;\n\tbh=ZSJUnaUaJh0Pjrg+PA8fqdsyGljWlZ9sbsKimyGVVZc=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=dk27sjs121FIBvUMIgWvbzf3hECruSYiDA3gDXQaEmLzinQjZpxmhvGMhJZFTZwj0\n\tX9I0gmumnnT24wLwJSHsFomEa6vfk4TKyJ2WLqvieB7gdhv54cnXiQzeiXzGYw9iPW\n\t/psjya3uo+sI6zkxtYj3vFnuuSa2bTsVlsWiB+kc=","Date":"Fri, 16 Aug 2024 17:04:09 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Milan Zamazal <mzamazal@redhat.com>","Cc":"Kieran Bingham <kieran.bingham@ideasonboard.com>,\n\tMaarten Lankhorst <dev@lankhorst.se>, libcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","Message-ID":"<20240816140409.GB19657@pendragon.ideasonboard.com>","References":"<20240815093715.165305-1-dev@lankhorst.se>\n\t<172371549845.2731480.17326395158292123568@ping.linuxembedded.co.uk>\n\t<87a5hcy49u.fsf@redhat.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<87a5hcy49u.fsf@redhat.com>","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":30855,"web_url":"https://patchwork.libcamera.org/comment/30855/","msgid":"<20240817173452.GB29320@pendragon.ideasonboard.com>","date":"2024-08-17T17:34:52","subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"On Fri, Aug 16, 2024 at 05:12:28PM +0200, Milan Zamazal wrote:\n> Laurent Pinchart <laurent.pinchart@ideasonboard.com> writes:\n> > On Fri, Aug 16, 2024 at 03:40:45PM +0200, Milan Zamazal wrote:\n> >> Kieran Bingham <kieran.bingham@ideasonboard.com> writes:\n> >> \n> >> > Hi Maarten,\n> >> >\n> >> > Thank you for highlighting this. I'm curious that it hasn't come up in\n> >> > our builds yet! What version of clang are you using?\n> >> \n> >> It happens to me too, with clang 18.1.6 on Fedora 40.\n> >\n> > I'm very surprised, I tested with clang 18.1.8 locally and didn't see\n> > any error. I would have fixed it already otherwise :-)\n> \n> Interesting.  I checked in another environment with clang 17.0.6 and it\n> also reports the error.  Can it perhaps depend on particular C/C++\n> header setup/version?  When I ask LSP about `abs' at the given place,\n> it points me to the following from stdlib.h:\n> \n>   extern int abs (int __x) __THROW __attribute__ ((__const__)) __wur;\n\nWell regardless of where the problem comes from, I think we should fix\nit. I'll review a v2 that uses std::abs(), and ideally addresses\nalsc.cpp too.\n\n> >> > Quoting Maarten Lankhorst (2024-08-15 10:37:15)\n> >> >> I was getting the following error in clang:\n> >> >> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: error: using integer absolute value function 'abs' when argument is of floating point type [-Werror,-Wabsolute-value]\n> >> >>         if (abs(denominator) > eps) {\n> >> >>             ^\n> >> >> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: note: use function 'std::abs' instead\n> >> >\n> >> > Is there a preference against the recommended std::abs?\n> >> >\n> >> >>         if (abs(denominator) > eps) {\n> >> >>             ^~~\n> >> >>             std::abs\n> >> >> \n> >> >> Signed-off-by: Maarten Lankhorst <dev@lankhorst.se>\n> >> >> ---\n> >> >>  src/ipa/rpi/controller/rpi/awb.cpp | 2 +-\n> >> >>  1 file changed, 1 insertion(+), 1 deletion(-)\n> >> >> \n> >> >> diff --git a/src/ipa/rpi/controller/rpi/awb.cpp b/src/ipa/rpi/controller/rpi/awb.cpp\n> >> >> index f45525bc..c5750c84 100644\n> >> >> --- a/src/ipa/rpi/controller/rpi/awb.cpp\n> >> >> +++ b/src/ipa/rpi/controller/rpi/awb.cpp\n> >> >> @@ -505,7 +505,7 @@ static double interpolateQuadatric(ipa::Pwl::Point const &a, ipa::Pwl::Point con\n> >> >>         const double eps = 1e-3;\n> >> >>         ipa::Pwl::Point ca = c - a, ba = b - a;\n> >> >>         double denominator = 2 * (ba.y() * ca.x() - ca.y() * ba.x());\n> >> >> -       if (abs(denominator) > eps) {\n> >> >> +       if (fabs(denominator) > eps) {\n> >> >>                 double numerator = ba.y() * ca.x() * ca.x() - ca.y() * ba.x() * ba.x();\n> >> >>                 double result = numerator / denominator + a.x();\n> >> >>                 return std::max(a.x(), std::min(c.x(), result));","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id A0100C323E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSat, 17 Aug 2024 17:35:23 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 4E20D633BD;\n\tSat, 17 Aug 2024 19:35:22 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id BF96963382\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 17 Aug 2024 19:35:19 +0200 (CEST)","from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 814DC3D5;\n\tSat, 17 Aug 2024 19:34:19 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"XjaY6wke\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1723916059;\n\tbh=VVp11RalTuyRS9Pes2KHCiwYidDttbd/TbcfiNdU+Mk=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=XjaY6wkekHV5k7kLwJwtTt9+VKzU1cskW8l23rZPQrMlU5kHnISbk2q92MB26BWRS\n\tXlUgOEx8h+dMcKHil01Q3LXwNipADx5FTGwljgUaVHf9OzPwqWGyqaAJNX2JX5NRnt\n\t8trD1IG8Z5W14nA8RyqJbmT+H0+SssZ7kF1CaC3U=","Date":"Sat, 17 Aug 2024 20:34:52 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Milan Zamazal <mzamazal@redhat.com>","Cc":"Kieran Bingham <kieran.bingham@ideasonboard.com>,\n\tMaarten Lankhorst <dev@lankhorst.se>, libcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","Message-ID":"<20240817173452.GB29320@pendragon.ideasonboard.com>","References":"<20240815093715.165305-1-dev@lankhorst.se>\n\t<172371549845.2731480.17326395158292123568@ping.linuxembedded.co.uk>\n\t<87a5hcy49u.fsf@redhat.com>\n\t<20240816140409.GB19657@pendragon.ideasonboard.com>\n\t<87wmkgwlgj.fsf@redhat.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<87wmkgwlgj.fsf@redhat.com>","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":30858,"web_url":"https://patchwork.libcamera.org/comment/30858/","msgid":"<87wmkdnev3.fsf@redhat.com>","date":"2024-08-19T07:36:32","subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","submitter":{"id":177,"url":"https://patchwork.libcamera.org/api/people/177/","name":"Milan Zamazal","email":"mzamazal@redhat.com"},"content":"Laurent Pinchart <laurent.pinchart@ideasonboard.com> writes:\n\n> On Fri, Aug 16, 2024 at 05:12:28PM +0200, Milan Zamazal wrote:\n>> Laurent Pinchart <laurent.pinchart@ideasonboard.com> writes:\n>> > On Fri, Aug 16, 2024 at 03:40:45PM +0200, Milan Zamazal wrote:\n>\n>> >> Kieran Bingham <kieran.bingham@ideasonboard.com> writes:\n>> >> \n>> >> > Hi Maarten,\n>> >> >\n>> >> > Thank you for highlighting this. I'm curious that it hasn't come up in\n>> >> > our builds yet! What version of clang are you using?\n>> >> \n>> >> It happens to me too, with clang 18.1.6 on Fedora 40.\n>> >\n>> > I'm very surprised, I tested with clang 18.1.8 locally and didn't see\n>> > any error. I would have fixed it already otherwise :-)\n>> \n>> Interesting.  I checked in another environment with clang 17.0.6 and it\n>> also reports the error.  Can it perhaps depend on particular C/C++\n>> header setup/version?  When I ask LSP about `abs' at the given place,\n>> it points me to the following from stdlib.h:\n>> \n>>   extern int abs (int __x) __THROW __attribute__ ((__const__)) __wur;\n>\n> Well regardless of where the problem comes from, I think we should fix\n> it. \n\nDefinitely.  But it would be interesting to know why it hasn't been\ncaught by the CI.\n\n> I'll review a v2 that uses std::abs(), and ideally addresses alsc.cpp\n> too.\n\nThank you.\n\n>> >> > Quoting Maarten Lankhorst (2024-08-15 10:37:15)\n>> >> >> I was getting the following error in clang:\n>> >> >> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: error: using integer absolute value function 'abs' when argument is of floating point type [-Werror,-Wabsolute-value]\n>> >> >>         if (abs(denominator) > eps) {\n>> >> >>             ^\n>> >> >> ../src/ipa/rpi/controller/rpi/awb.cpp:508:6: note: use function 'std::abs' instead\n>> >> >\n>> >> > Is there a preference against the recommended std::abs?\n>> >> >\n>> >> >>         if (abs(denominator) > eps) {\n>> >> >>             ^~~\n>> >> >>             std::abs\n>> >> >> \n>> >> >> Signed-off-by: Maarten Lankhorst <dev@lankhorst.se>\n>> >> >> ---\n>> >> >>  src/ipa/rpi/controller/rpi/awb.cpp | 2 +-\n>> >> >>  1 file changed, 1 insertion(+), 1 deletion(-)\n>> >> >> \n>> >> >> diff --git a/src/ipa/rpi/controller/rpi/awb.cpp b/src/ipa/rpi/controller/rpi/awb.cpp\n>> >> >> index f45525bc..c5750c84 100644\n>> >> >> --- a/src/ipa/rpi/controller/rpi/awb.cpp\n>> >> >> +++ b/src/ipa/rpi/controller/rpi/awb.cpp\n>> >> >> @@ -505,7 +505,7 @@ static double interpolateQuadatric(ipa::Pwl::Point const &a, ipa::Pwl::Point con\n>> >> >>         const double eps = 1e-3;\n>> >> >>         ipa::Pwl::Point ca = c - a, ba = b - a;\n>> >> >>         double denominator = 2 * (ba.y() * ca.x() - ca.y() * ba.x());\n>> >> >> -       if (abs(denominator) > eps) {\n>> >> >> +       if (fabs(denominator) > eps) {\n>> >> >>                 double numerator = ba.y() * ca.x() * ca.x() - ca.y() * ba.x() * ba.x();\n>> >> >>                 double result = numerator / denominator + a.x();\n>> >> >>                 return std::max(a.x(), std::min(c.x(), result));","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id B4BDFC323E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 19 Aug 2024 07:36:42 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id F22EC63394;\n\tMon, 19 Aug 2024 09:36:41 +0200 (CEST)","from us-smtp-delivery-124.mimecast.com\n\t(us-smtp-delivery-124.mimecast.com [170.10.133.124])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id ADD7C6337E\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 19 Aug 2024 09:36:39 +0200 (CEST)","from mail-ed1-f72.google.com (mail-ed1-f72.google.com\n\t[209.85.208.72]) by relay.mimecast.com with ESMTP with STARTTLS\n\t(version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id\n\tus-mta-416-lR28ZV7dP_6oPpUNTjR3iQ-1; Mon, 19 Aug 2024 03:36:36 -0400","by mail-ed1-f72.google.com with SMTP id\n\t4fb4d7f45d1cf-5beb4ecad6dso2490003a12.3\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 19 Aug 2024 00:36:36 -0700 (PDT)","from nuthatch (ip-77-48-47-2.net.vodafone.cz. [77.48.47.2])\n\tby smtp.gmail.com with ESMTPSA id\n\t4fb4d7f45d1cf-5bef1261249sm1503445a12.6.2024.08.19.00.36.33\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tMon, 19 Aug 2024 00:36:33 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=redhat.com header.i=@redhat.com\n\theader.b=\"BWrSwnj5\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n\ts=mimecast20190719; t=1724052998;\n\th=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n\tto:to:cc:cc:mime-version:mime-version:content-type:content-type:\n\tin-reply-to:in-reply-to:references:references;\n\tbh=wKqpv+lTue9fiwqfFjZFLZpHwIMqsbcUQrRzsMjpBiM=;\n\tb=BWrSwnj5aK/cSJIzWlPadpQ5WHuGRiTn2Gj5U9e6ay7iVSWUq3gVz4SUElKzPyQAaFYGJB\n\tV7NXshQScyVYSCSfQeIhCQrXi7apCVXYZRmoIrnHKRO6kou+g7I9znoMPyTszAC14SHsAO\n\t6nL1KE9M6slBM8p06yxlzYwHKxQFgoA=","X-MC-Unique":"lR28ZV7dP_6oPpUNTjR3iQ-1","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1724052995; x=1724657795;\n\th=mime-version:user-agent:message-id:date:references:in-reply-to\n\t:subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date\n\t:message-id:reply-to;\n\tbh=wKqpv+lTue9fiwqfFjZFLZpHwIMqsbcUQrRzsMjpBiM=;\n\tb=IEqzcEuVWbDkUDpCsPPh4g2WEiXWPYYsedyf4k1ysOg6+a/3QZBpqZjVqma1U/dC0I\n\t0st8du61k4JkJg0mBeGyE6jor0IohOZBhxMLKi8JdmOpiDZfTX+J41Q84xmgCIqB1ZPn\n\tXRTkLrFTvj2tVQ7avL7HEO0gL6pcULF6hEQpJPzOvDawKTo7zH8DEL+SbuCzELd17E3E\n\t3txzJBsEyEj0HRdc7HvZmGSVSuquZCkfgdjcHbdIZG2bm+jo/uSnGTcBBmSl1m3xoVUF\n\tcjlS7U3rdwT28nwwu/zuZlv9m7IC9EFXunO6lH5wGvmf5Ce0AgYBZ4MJVJSJW3Er6YOx\n\tSHYA==","X-Forwarded-Encrypted":"i=1;\n\tAJvYcCXLgnApdmLGHcyaK6/jpZBIkGBOxvhglB+lgZU44KYB7PHkN5XY1Rh5jb/6zC4wKNSf123qo2NyEJvde89aZqvH/e7aKlsTT2aqmQ+TiQfJfNUl6w==","X-Gm-Message-State":"AOJu0YyCYKCQcLopW6+yhb8adUFM4f5BcqHPyOXF+R6BCLvhiS7TRzDC\n\tiso7vfgXZUGwrbwiqE9E74FMkrza0S0JcOVXupUZZF8a2w+S36I2DO9xzffoo6ueccVqv+cQgcK\n\tFUDtKtAdzhwACWTyVzYmGopcTD09ErmNUJtIkhecXEKP4DuHP1u1My5Or8erM5qtLiucH6f1YoQ\n\tHYxR1i586tVyrFY7SSnk1yyaXHaIkKeft3a3VIEKOCw68lWArfaMtbz5Y=","X-Received":["by 2002:a05:6402:1e94:b0:5be:d9ac:c776 with SMTP id\n\t4fb4d7f45d1cf-5bed9accabdmr4805103a12.38.1724052994658; \n\tMon, 19 Aug 2024 00:36:34 -0700 (PDT)","by 2002:a05:6402:1e94:b0:5be:d9ac:c776 with SMTP id\n\t4fb4d7f45d1cf-5bed9accabdmr4805085a12.38.1724052994137; \n\tMon, 19 Aug 2024 00:36:34 -0700 (PDT)"],"X-Google-Smtp-Source":"AGHT+IFRsba7LdPgyyYIodfxDR0gzD2/IjehHsT9FPEhjCFV3XglV47FAKc1BZsXdrMpRttr8tlZaQ==","From":"Milan Zamazal <mzamazal@redhat.com>","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","Cc":"Kieran Bingham <kieran.bingham@ideasonboard.com>,  Maarten Lankhorst\n\t<dev@lankhorst.se>,  libcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH] ipa/rpi/controller: Use fabs for calculating absolute\n\tvalues","In-Reply-To":"<20240817173452.GB29320@pendragon.ideasonboard.com> (Laurent\n\tPinchart's message of \"Sat, 17 Aug 2024 20:34:52 +0300\")","References":"<20240815093715.165305-1-dev@lankhorst.se>\n\t<172371549845.2731480.17326395158292123568@ping.linuxembedded.co.uk>\n\t<87a5hcy49u.fsf@redhat.com>\n\t<20240816140409.GB19657@pendragon.ideasonboard.com>\n\t<87wmkgwlgj.fsf@redhat.com>\n\t<20240817173452.GB29320@pendragon.ideasonboard.com>","Date":"Mon, 19 Aug 2024 09:36:32 +0200","Message-ID":"<87wmkdnev3.fsf@redhat.com>","User-Agent":"Gnus/5.13 (Gnus v5.13)","MIME-Version":"1.0","X-Mimecast-Spam-Score":"0","X-Mimecast-Originator":"redhat.com","Content-Type":"text/plain","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]