From patchwork Wed Sep 9 17:21:27 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Emil Velikov X-Patchwork-Id: 7147651 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 2E39FBEEC1 for ; Wed, 9 Sep 2015 17:17:34 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 5964F20567 for ; Wed, 9 Sep 2015 17:17:33 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 7C19520A06 for ; Wed, 9 Sep 2015 17:17:32 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 8B1F36EC81; Wed, 9 Sep 2015 10:17:31 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wi0-f169.google.com (mail-wi0-f169.google.com [209.85.212.169]) by gabe.freedesktop.org (Postfix) with ESMTPS id 563796EC88 for ; Wed, 9 Sep 2015 10:17:29 -0700 (PDT) Received: by wicfx3 with SMTP id fx3so165063108wic.1 for ; Wed, 09 Sep 2015 10:17:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=5XwJmRemcySu7yTV+zWYS6xZynAgXFfp/K5Qhc5yoj0=; b=uSls8A8nDY+1rNkITh9aVLXhaa0km4Nczu5SFJoGkCaxDfiufXlpHUUEXvdkQGiSoY OVCMyhNB1hRcGqOVUBqGuiWmsN/ISa+7xkZadPBYOl66lTPIwwu6ZompE9BmiaCuh094 D+Rs+Tb7KgGA9/d8eQoD9f/U0oq9rvu5yq3wCNufRvGLrf7vHuIhcav6bg+ZOkX8ajqI 0qMvrYL+DoVGSNHeierdUk8k4plr1KFhSEsNtE/P18fm5ujnTtbMQIB6pUlDm/2AZuTx g7qP1c83VHt/GQfkFn5aJ3S2qbshDO2VaJM63zUILlbKdU6mc2sMwNhh49O87jVxPjay cV1Q== X-Received: by 10.180.87.71 with SMTP id v7mr55630056wiz.21.1441819048013; Wed, 09 Sep 2015 10:17:28 -0700 (PDT) Received: from arch-x220.localdomain (cpc12-croy20-2-0-cust52.croy.cable.virginm.net. [82.44.54.53]) by smtp.gmail.com with ESMTPSA id j7sm11257042wjz.11.2015.09.09.10.17.26 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 09 Sep 2015 10:17:27 -0700 (PDT) From: Emil Velikov To: dri-devel@lists.freedesktop.org Subject: [PATCH libdrm 06/12] util_math: add MAX3 macro Date: Wed, 9 Sep 2015 18:21:27 +0100 Message-Id: <1441819293-25567-7-git-send-email-emil.l.velikov@gmail.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1441819293-25567-1-git-send-email-emil.l.velikov@gmail.com> References: <1441819293-25567-1-git-send-email-emil.l.velikov@gmail.com> Cc: emil.l.velikov@gmail.com X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Emil Velikov --- util_math.h | 1 + 1 file changed, 1 insertion(+) diff --git a/util_math.h b/util_math.h index 3bc5f64..02b15a8 100644 --- a/util_math.h +++ b/util_math.h @@ -26,6 +26,7 @@ #define MIN2( A, B ) ( (A)<(B) ? (A) : (B) ) #define MAX2( A, B ) ( (A)>(B) ? (A) : (B) ) +#define MAX3( A, B, C ) ((A) > (B) ? MAX2(A, C) : MAX2(B, C)) #define __align_mask(value, mask) (((value) + (mask)) & ~(mask)) #define ALIGN(value, alignment) __align_mask(value, (typeof(value))((alignment) - 1))