Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp35727898rwd; Mon, 10 Jul 2023 11:36:39 -0700 (PDT) X-Google-Smtp-Source: APBJJlESx5mcBTbxXV4NAIWd99glclQq9ZHSacN2EvS6EJQSMU3CJKo4rFXlAIfDbazT5anQFfMl X-Received: by 2002:a17:906:154:b0:993:eb4b:ed51 with SMTP id 20-20020a170906015400b00993eb4bed51mr10475467ejh.27.1689014198785; Mon, 10 Jul 2023 11:36:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689014198; cv=none; d=google.com; s=arc-20160816; b=Cdc31GfGQlVpTgq5Nd2onYAHa6pHpNnKzZMX7wF4gzX9oyuVHXfK5noK2dFpi8A7hD 4aC2H60fVyyZf5LL/+3Hr3jcV3Nwqt3G66XmN482hSuzMJvdEenMx+mKNPDNvpepFHq6 AnNBaKYVZQj8XwLw21FG4UqnB5+nzwBEv9E3ZzoR36s5zmKXxwQKuFROD1Q5miQaNOSk 5ReTFoXnrxbAXzCYtfC07lRjPaFtWdjGcLqWCxjbFoUhtdPby0Whr8OJl4rglu8rkn4e L0VeVKjwVm1lpEV2KlUV3p5qlRhLq+95NEdTXcacpUpq47TMGUEa4rXB5ZjTLhARK8E9 Dksg== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=+E+JGqEgh6Ho5BCsKU8PDJIRdlqG8t2VArGsoWiGuQE=; fh=odud58AEZ8dpT9wVpEi49z2KFyKsW9gCOcsWyWRzkG0=; b=GhvO7ib+h9icc1Cz9rkdt4NrKoo6j5Bw3OmQXrlDE4wQPPw5X2kIsubTYcg5cHPmBP ULaZNg5BuevqvOjRT9J7SldjNGzOLWZVGVtfl9qK2Jvnzkd/vfKGzUeyAmONQjTc9NHP EcDueHlQnqVgPJM1nb1YiLqQ84h1PGnIxU8BBgR72v2/bwjcIJTDQIsgqNemt9O3dxOy +az3YkxJrqLqXlA6K/pzZ1BFFijvPqFri081opd78Yd7Id8mElhvlNKDYdIPaP7ikqDh O5WVCWJbXLaNlugIh5hlmOib45moiirzIs7/jSxkN+oVng2Azv0eYfHjyjZjxV68YOll go6Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i20-20020a170906091400b00977ca821ed8si130284ejd.584.2023.07.10.11.36.13; Mon, 10 Jul 2023 11:36:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233106AbjGJRYJ (ORCPT + 99 others); Mon, 10 Jul 2023 13:24:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43584 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232821AbjGJRXn (ORCPT ); Mon, 10 Jul 2023 13:23:43 -0400 Received: from cloudserver094114.home.pl (cloudserver094114.home.pl [79.96.170.134]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B46D9137; Mon, 10 Jul 2023 10:23:41 -0700 (PDT) Received: from localhost (127.0.0.1) (HELO v370.home.net.pl) by /usr/run/smtp (/usr/run/postfix/private/idea_relay_lmtp) via UNIX with SMTP (IdeaSmtpServer 5.2.0) id 1e24d625bc52e79f; Mon, 10 Jul 2023 19:23:40 +0200 Received: from kreacher.localnet (unknown [195.136.19.94]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by v370.home.net.pl (Postfix) with ESMTPSA id BCE38660DCF; Mon, 10 Jul 2023 19:23:39 +0200 (CEST) From: "Rafael J. Wysocki" To: Linux ACPI Cc: LKML , Bob Moore , Saket Dumbre Subject: [PATCH 03/14] ACPICA: exserial.c: replace ternary operator with ACPI_MIN() Date: Mon, 10 Jul 2023 19:13:05 +0200 Message-ID: <1865812.tdWV9SEqCh@kreacher> In-Reply-To: <5698695.DvuYhMxLoT@kreacher> References: <5698695.DvuYhMxLoT@kreacher> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="UTF-8" X-CLIENT-IP: 195.136.19.94 X-CLIENT-HOSTNAME: 195.136.19.94 X-VADE-SPAMSTATE: clean X-VADE-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedviedrvdekgddutdefucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecujffqoffgrffnpdggtffipffknecuuegrihhlohhuthemucduhedtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefhvfevufffkfgjfhgggfgtsehtufertddttdejnecuhfhrohhmpedftfgrfhgrvghlucflrdcuhgihshhotghkihdfuceorhhjfiesrhhjfiihshhotghkihdrnhgvtheqnecuggftrfgrthhtvghrnhepledtieekkeekveeikeetgffgteeuteefjeevjeegudelvdduheeiuedvieehieevnecuffhomhgrihhnpehgihhthhhusgdrtghomhenucfkphepudelhedrudefiedrudelrdelgeenucevlhhushhtvghrufhiiigvpedvnecurfgrrhgrmhepihhnvghtpeduleehrddufeeirdduledrleegpdhhvghlohepkhhrvggrtghhvghrrdhlohgtrghlnhgvthdpmhgrihhlfhhrohhmpedftfgrfhgrvghlucflrdcuhgihshhotghkihdfuceorhhjfiesrhhjfiihshhotghkihdrnhgvtheqpdhnsggprhgtphhtthhopeegpdhrtghpthhtoheplhhinhhugidqrggtphhisehvghgvrhdrkhgvrhhnvghlrdhorhhgpdhrtghpthhtoheplhhinhhugidqkhgvrhhnvghlsehvghgvrhdrkhgvrhhnvghlrdhorhhgpdhrtghpthhtoheprhhosggvrhhtrdhmohhorhgvsehinhhtvghlrdgtohhmpdhrtghpthhtohepshgrkhgvthdrughumhgsrhgv sehinhhtvghlrdgtohhm X-DCC--Metrics: v370.home.net.pl 1024; Body=4 Fuz1=4 Fuz2=4 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jiangshan Yi ACPICA commit 2250f71fe77396db21df805222ffcbf19e1e7896 Make the code simpler and more readable. Link: https://github.com/acpica/acpica/commit/2250f71f Signed-off-by: Jiangshan Yi Signed-off-by: Bob Moore Signed-off-by: Rafael J. Wysocki --- drivers/acpi/acpica/exserial.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/acpi/acpica/exserial.c b/drivers/acpi/acpica/exserial.c index 5d99b1a76c83..5241f4c01c76 100644 --- a/drivers/acpi/acpica/exserial.c +++ b/drivers/acpi/acpica/exserial.c @@ -343,8 +343,7 @@ acpi_ex_write_serial_bus(union acpi_operand_object *source_desc, /* Copy the input buffer data to the transfer buffer */ buffer = buffer_desc->buffer.pointer; - data_length = (buffer_length < source_desc->buffer.length ? - buffer_length : source_desc->buffer.length); + data_length = ACPI_MIN(buffer_length, source_desc->buffer.length); memcpy(buffer, source_desc->buffer.pointer, data_length); /* Lock entire transaction if requested */ -- 2.35.3