From patchwork Tue Oct 8 16:21:15 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gregory Rose X-Patchwork-Id: 1173420 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=openvswitch.org (client-ip=140.211.169.12; helo=mail.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="RwhVHueB"; dkim-atps=neutral Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 46njK04S71z9sP7 for ; Wed, 9 Oct 2019 03:21:23 +1100 (AEDT) Received: from mail.linux-foundation.org (localhost [127.0.0.1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 2942ECCB; Tue, 8 Oct 2019 16:21:22 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id 44CA0CCA for ; Tue, 8 Oct 2019 16:21:21 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.7.6 Received: from mail-pf1-f194.google.com (mail-pf1-f194.google.com [209.85.210.194]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id 32A828A8 for ; Tue, 8 Oct 2019 16:21:20 +0000 (UTC) Received: by mail-pf1-f194.google.com with SMTP id b128so11084844pfa.1 for ; Tue, 08 Oct 2019 09:21:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=jRT79hdKl9RBJ+RuVP5tX90gZjoSOLaqOXlCxDW6B/c=; b=RwhVHueBw3u2mh1KXdLJryqtVpMeyuvfKpyTW2ywEBwGH9ljNqs6YAUCjOimYnVITp PisTnkAFGUYbQRxO6Ra9RLXgFBoThBhm7YOi7lr2HNhuM3zPODBtg5u8t7fgBexf4yGa AsAjNQhDcjsLiCfiWrvpK3izh0Jfvan1ikUlcLmoRGb3aCmGztvFvP1XVKL5yDrUWhSn AvCec2BB5tkvY6LspFVZiRF2Hbd9LIenimQcZrDN8CgxntwnXNHoK7PCFWnfVXYteZ8L z5R7qR5smNZtpiqhGpG4qowvOsjzQ4038qaTImhxQ32ccTxo5dY7O9l/mwScH5icZDS5 djww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=jRT79hdKl9RBJ+RuVP5tX90gZjoSOLaqOXlCxDW6B/c=; b=lgDd4xIAgJfMd+P6bwhx6Rzhd/GnlYKcMLZVWuFf2gDAEdJL4yGyCRbFtCWZVHyZI4 0B7FkT1n7S7XhUEsHceZU9cSPWm3HlF2MltwePNr9tfelStjPYt7Ax6E8YYN4OXxtIs+ PT+w7dgOQICI//z7Ey3viDj+LKNFV/28bO7OS5KmFEHX7z+jGEUZ4zwlKns9Y7e5Ra+o +/r7pk2jTKZ3o4ICgsAXvuwDP8L6TWYuRFa+00DZECA/Qa3zoWaWCKJldVxJEtBBu7Wf ZqSBgPzBcQHm6mawF0qxHfkxGSzOGwlADJqYcdmXw0ZPKq6MBmnzSpWpIlYnz9Ha3kYY aULg== X-Gm-Message-State: APjAAAXEH1WWvCCsh10k7OBJ1avsF+gOcxgs0AutHSZS9bRObl+K1t6K kgtjcXpreMJ9+4Sfl+LW4gYKcI3R X-Google-Smtp-Source: APXvYqwCbASvHdX8mApOEtUXA4+bqrX1pQytDbD9OX8VzFlxYv34Goe9dOjBJRjZlGE5D7tuCvlzXw== X-Received: by 2002:a63:1963:: with SMTP id 35mr14310154pgz.138.1570551679146; Tue, 08 Oct 2019 09:21:19 -0700 (PDT) Received: from gizo.domain (97-115-119-26.ptld.qwest.net. [97.115.119.26]) by smtp.gmail.com with ESMTPSA id j10sm15789723pfn.128.2019.10.08.09.21.17 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 08 Oct 2019 09:21:18 -0700 (PDT) From: Greg Rose To: dev@openvswitch.org Date: Tue, 8 Oct 2019 09:21:15 -0700 Message-Id: <1570551675-22643-1-git-send-email-gvrose8192@gmail.com> X-Mailer: git-send-email 1.8.3.1 X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE autolearn=no version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on smtp1.linux-foundation.org Subject: [ovs-dev] [PATCH] acinclude: Fix false positive search for prandom_u32 X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: ovs-dev-bounces@openvswitch.org Errors-To: ovs-dev-bounces@openvswitch.org Searching random.h for prandom_u32 will also match when prandom_u32_max is present and cause a false positive HAVE_PRANDOM_U32. Fix this up by looking for the parenthesis following prandom_u32 so it won't match on prandom_u32_max. Passes Travis: https://travis-ci.org/gvrose8192/ovs-experimental/builds/595171808 Signed-off-by: Greg Rose Reviewed-by: Yifeng Sun --- acinclude.m4 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/acinclude.m4 b/acinclude.m4 index c729266..066c134 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -723,7 +723,9 @@ AC_DEFUN([OVS_CHECK_LINUX_COMPAT], [ [\(*nf_ct_timeout_find_get_hook\)], [net], [OVS_DEFINE([HAVE_NF_CT_TIMEOUT_FIND_GET_HOOK_NET])]) - OVS_GREP_IFELSE([$KSRC/include/linux/random.h], [prandom_u32]) + OVS_GREP_IFELSE([$KSRC/include/linux/random.h], + [prandom_u32[[\(]]], + [OVS_DEFINE([HAVE_PRANDOM_U32])]) OVS_GREP_IFELSE([$KSRC/include/linux/random.h], [prandom_u32_max]) OVS_GREP_IFELSE([$KSRC/include/net/rtnetlink.h], [get_link_net])