Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp415269ybe; Fri, 6 Sep 2019 01:19:17 -0700 (PDT) X-Google-Smtp-Source: APXvYqzAFjWFwyRRTbVKnh4Vgsqppdpa9xNhwAuNl5xNVL8cxAmnpgfC1F6x9jXh/ClyZycC/0vW X-Received: by 2002:a17:902:e60d:: with SMTP id cm13mr7866307plb.178.1567757957097; Fri, 06 Sep 2019 01:19:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567757957; cv=none; d=google.com; s=arc-20160816; b=Oq9M7Z1pudjFGMkJCOfcqVVzA8+5hi0Oab3NluejZYS9fYQCAnuuRmj9JWYLKnIfL3 fBNx7+J3GjPS9Pqnkn6yUT5iAjLDRw5fvgLVz2O8BiWzSeHxPdZYhufvzTBUnpUu/oYU ESi/JO6Gd/wy5P6Un9rv4H1RkX0mpJpDdm1P7BH64uMMrpO+L0wPHXdlP35on7tQtYMx US1vk6zUlvdZU+5JX3lm9mHdzeTKnC7KJ+Fkz6Tv7iw+tyB7UloeinECTLeSNi4koV2l vvT8OFvolOIU0pH/hJXCUS9xrb2+PNV0IrMCZGeBK6fVqDxw4U3vBjx6xuFERMpRvTYz HyzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:from:subject:mime-version :message-id:date:dkim-signature; bh=5OIWaQS8XUylUqWEOLvRcQ6wvtAGUWcmHb4qQooXQU4=; b=FnOk9xb+ZPPi9U6aGpfVtZL1nXBQyEXT/K+8dObGdMAzqnEYMVWWnzeYy1cH+uhS8d i8zLRVm1Oyhpnqulm32z4Re7qY0JdmIr9LrGgWVUToc6A0omO6pR8e6ogrRWQfQDxFAU jKqt+5dEOTLnS6i4Ga7gHURKeXeR/cp1/MC2G5z07FuF9Qgx5TvZIJWOh8f9qHvlVWr7 JS/tXSESNNXiTnVF6mfZDK+V4Tusz2tWz3SdNOxhauerOsqTbeWgo0Ufr3gb+8MGoFyr 2oRKIu1YzZzNVxdZuZSrqWMcqVwFE55a3CGxzLVmkSr9K7pwzW0vA4iHPeUuDPeAm72v Qx1g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=sqoOcBxZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a16si3777295pgw.156.2019.09.06.01.19.01; Fri, 06 Sep 2019 01:19:17 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=sqoOcBxZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391824AbfIEVPg (ORCPT + 99 others); Thu, 5 Sep 2019 17:15:36 -0400 Received: from mail-pf1-f202.google.com ([209.85.210.202]:39983 "EHLO mail-pf1-f202.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2391791AbfIEVPg (ORCPT ); Thu, 5 Sep 2019 17:15:36 -0400 Received: by mail-pf1-f202.google.com with SMTP id v15so2801474pfe.7 for ; Thu, 05 Sep 2019 14:15:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:message-id:mime-version:subject:from:to:cc; bh=5OIWaQS8XUylUqWEOLvRcQ6wvtAGUWcmHb4qQooXQU4=; b=sqoOcBxZdlqGDWySWP2Y/co94HGedfimwCSXcJFCDa2CSHTgUIbVs4Pv6YfiqW989D qwxLXD2E6ccpMCJrXFqhjsQ8KvKmii4DOcdayDCxOPHgZnS3MYlw7VykblxC7tziuiWg TGPazBMqwY4jU9+ikaAjXWzQA567E4smuiqVvfBzdgaMlJPhw+KkxBjnb4RpotPIP0yv 4To4Fb74sAf5hCcy3mrBjhnNGk5/27rRSbZnG99BZMVY57d6quzmuw/KdICvu3J8iC9a ndMLLbyFrE67/RIXYeSI2gDac9o0MrmV7qytiMO9xmjTphHOMt5lwQ4Jjd8n6/kFiDV6 qRhQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:message-id:mime-version:subject:from:to:cc; bh=5OIWaQS8XUylUqWEOLvRcQ6wvtAGUWcmHb4qQooXQU4=; b=BKxGwImCyS3oVlF7B2xb+6AM7QU9186yLgiI/g1bSZn/fv7b1Bk1mGSjh4OCViwWhp 6nI2J/MHIN1Vpr4b77ooeCj4Exzisn8azcqHi5BYZa5oBeGSN3BMc7OT2qMYXXH60mBv VAIKEYW9PZqh8Kc/2edpArPobICFgpMi2EMUrSC8GqRtyhHO4Bch6o6TwzSktyDq6mfF 2mNoo+175QV1QbyL4hpMO+qGfzW27ZIaVH95YT22sh8fKRAaje/FItygTFPvhjRXDTL9 kxEDf+ayw61P7h4uc3PLx3v0P+Zm2Usum+zVrS8Q1Y+XVfahbDMNsyhBvj3BmcZqZ8P5 Mq0w== X-Gm-Message-State: APjAAAVNeXmWA+g6Jz93X8bfmjNcEucR9r1APdrvZSaKKv4llZf+0jqy 1UKo9i1mLy45ZvwmMjtKAsqrkVB2FRmPUMHZpB8= X-Received: by 2002:a63:2252:: with SMTP id t18mr5065062pgm.5.1567718135010; Thu, 05 Sep 2019 14:15:35 -0700 (PDT) Date: Thu, 5 Sep 2019 14:15:28 -0700 Message-Id: <20190905211528.97828-1-samitolvanen@google.com> Mime-Version: 1.0 X-Mailer: git-send-email 2.23.0.187.g17f5b7556c-goog Subject: [PATCH] kcm: use BPF_PROG_RUN From: Sami Tolvanen To: "David S. Miller" , Tom Herbert Cc: netdev@vger.kernel.org, bpf@vger.kernel.org, linux-kernel@vger.kernel.org, Sami Tolvanen Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Instead of invoking struct bpf_prog::bpf_func directly, use the BPF_PROG_RUN macro. Signed-off-by: Sami Tolvanen --- net/kcm/kcmsock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/kcm/kcmsock.c b/net/kcm/kcmsock.c index 5dbc0c48f8cb..f350c613bd7d 100644 --- a/net/kcm/kcmsock.c +++ b/net/kcm/kcmsock.c @@ -379,7 +379,7 @@ static int kcm_parse_func_strparser(struct strparser *strp, struct sk_buff *skb) struct kcm_psock *psock = container_of(strp, struct kcm_psock, strp); struct bpf_prog *prog = psock->bpf_prog; - return (*prog->bpf_func)(skb, prog->insnsi); + return BPF_PROG_RUN(prog, skb); } static int kcm_read_sock_done(struct strparser *strp, int err) -- 2.23.0.187.g17f5b7556c-goog