From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1FEC2EB64DD for ; Thu, 3 Aug 2023 17:26:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233956AbjHCR04 (ORCPT ); Thu, 3 Aug 2023 13:26:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42322 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232007AbjHCR0z (ORCPT ); Thu, 3 Aug 2023 13:26:55 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A4E8A2D65 for ; Thu, 3 Aug 2023 10:26:53 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 3AACE61E4A for ; Thu, 3 Aug 2023 17:26:53 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 88ACFC433C9; Thu, 3 Aug 2023 17:26:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1691083612; bh=+grR1oM9bWabRdgaiCZlTN/MIN11vicmsa9gV8IBEAs=; h=Date:To:From:Subject:From; b=Pj1GF4/iKnFO+uLqRXqWNVcozgJzP2BcgzniS5TqzYYMwhmix16vh5H0Ak1H2rIZe 0l6/+G6ktavxDoBXHjQUPLE/aFXt0t+ZBeTTNvaab0iqYsnq8hE4Ls3cV+cNcVXknF 57N/b6aQ7v1Sp2DVisn6Yu1RIBB6lyQogCZ3Y990= Date: Thu, 03 Aug 2023 10:26:51 -0700 To: mm-commits@vger.kernel.org, tvrtko.ursulin@linux.intel.com, rodrigo.vivi@intel.com, p.zabel@pengutronix.de, linux@rasmusvillemoes.dk, joonas.lahtinen@linux.intel.com, jirislaby@kernel.org, jani.nikula@linux.intel.com, jani.nikula@intel.com, imre.deak@intel.com, gregkh@linuxfoundation.org, deller@gmx.de, daniel@ffwll.ch, andi.shyti@linux.intel.com, airlied@gmail.com, adobriyan@gmail.com, andriy.shevchenko@linux.intel.com, akpm@linux-foundation.org From: Andrew Morton Subject: + drm-i915-move-abs_diff-to-mathh.patch added to mm-nonmm-unstable branch Message-Id: <20230803172652.88ACFC433C9@smtp.kernel.org> Precedence: bulk Reply-To: linux-kernel@vger.kernel.org List-ID: X-Mailing-List: mm-commits@vger.kernel.org The patch titled Subject: drm/i915: Move abs_diff() to math.h has been added to the -mm mm-nonmm-unstable branch. Its filename is drm-i915-move-abs_diff-to-mathh.patch This patch will shortly appear at https://git.kernel.org/pub/scm/linux/kernel/git/akpm/25-new.git/tree/patches/drm-i915-move-abs_diff-to-mathh.patch This patch will later appear in the mm-nonmm-unstable branch at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/process/submit-checklist.rst when testing your code *** The -mm tree is included into linux-next via the mm-everything branch at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm and is updated there every 2-3 working days ------------------------------------------------------ From: Andy Shevchenko Subject: drm/i915: Move abs_diff() to math.h Date: Thu, 3 Aug 2023 16:19:18 +0300 abs_diff() belongs to math.h. Move it there. This will allow others to use it. Link: https://lkml.kernel.org/r/20230803131918.53727-1-andriy.shevchenko@linux.intel.com Signed-off-by: Andy Shevchenko Reviewed-by: Jiri Slaby # tty/serial Acked-by: Jani Nikula Acked-by: Greg Kroah-Hartman Reviewed-by: Andi Shyti Reviewed-by: Philipp Zabel # gpu/ipu-v3 Cc: Alexey Dobriyan Cc: Daniel Vetter Cc: David Airlie Cc: Helge Deller Cc: Imre Deak Cc: Jani Nikula Cc: Joonas Lahtinen Cc: Rasmus Villemoes Cc: Rodrigo Vivi Cc: Tvrtko Ursulin Signed-off-by: Andrew Morton --- drivers/gpu/drm/i915/display/intel_dpll_mgr.c | 1 + drivers/gpu/drm/i915/display/intel_dpll_mgr.h | 7 ------- drivers/gpu/ipu-v3/ipu-image-convert.c | 15 +++++++-------- drivers/tty/serial/omap-serial.c | 7 +------ drivers/video/fbdev/core/svgalib.c | 7 +------ include/linux/math.h | 7 +++++++ 6 files changed, 17 insertions(+), 27 deletions(-) --- a/drivers/gpu/drm/i915/display/intel_dpll_mgr.c~drm-i915-move-abs_diff-to-mathh +++ a/drivers/gpu/drm/i915/display/intel_dpll_mgr.c @@ -21,6 +21,7 @@ * DEALINGS IN THE SOFTWARE. */ +#include #include #include "i915_reg.h" --- a/drivers/gpu/drm/i915/display/intel_dpll_mgr.h~drm-i915-move-abs_diff-to-mathh +++ a/drivers/gpu/drm/i915/display/intel_dpll_mgr.h @@ -29,13 +29,6 @@ #include "intel_wakeref.h" -/*FIXME: Move this to a more appropriate place. */ -#define abs_diff(a, b) ({ \ - typeof(a) __a = (a); \ - typeof(b) __b = (b); \ - (void) (&__a == &__b); \ - __a > __b ? (__a - __b) : (__b - __a); }) - enum tc_port; struct drm_i915_private; struct intel_atomic_state; --- a/drivers/gpu/ipu-v3/ipu-image-convert.c~drm-i915-move-abs_diff-to-mathh +++ a/drivers/gpu/ipu-v3/ipu-image-convert.c @@ -7,7 +7,10 @@ #include #include +#include + #include