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 9F85EC6FA8B for ; Mon, 19 Sep 2022 13:21:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230161AbiISNVG (ORCPT ); Mon, 19 Sep 2022 09:21:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48032 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230292AbiISNVE (ORCPT ); Mon, 19 Sep 2022 09:21:04 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9BA542B252 for ; Mon, 19 Sep 2022 06:20:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1663593657; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=pJzkF9UKJ0JT/guvrtnnYyhgP8leVpTS5h5H8IUyZjs=; b=gj1H4nqkDcxH1Hyfkxo2LOMjrmTbm7k8Vd67pteVttXR0i1KXORXlABMqK5SgI6b2qg+nq NIy7Ag3m5Gjyelk35paKG6mNu7mF0Xuvtn9Zxiw6LJXqum50eS++L/EVFtuCuQsPMNEnvj tyon3OrXkXA+HQOjj5x6/0ENEiBO68k= Received: from mail-ed1-f70.google.com (mail-ed1-f70.google.com [209.85.208.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-596-ZOBmw6LLPquKX74i-c-JSQ-1; Mon, 19 Sep 2022 09:20:56 -0400 X-MC-Unique: ZOBmw6LLPquKX74i-c-JSQ-1 Received: by mail-ed1-f70.google.com with SMTP id z13-20020a05640240cd00b0045276a79364so12661311edb.2 for ; Mon, 19 Sep 2022 06:20:56 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date; bh=pJzkF9UKJ0JT/guvrtnnYyhgP8leVpTS5h5H8IUyZjs=; b=CMcb7gYRhysr6MWzH/gOSRvaerRu1yjMEklP/nPp9IThmh+1WGYNS8M+Gw6UZhLQBs q7CurLLf7ZBTY4qucRZ9lqhe/MxV47u1YfwsXNls76RRpUW/rXesl+zwKP9beal9LxDv dku+7Ul7cxy8t1h8epTk2LJWurPk+QgEMGMSK69FE68tSA6NgkwAL9G7WSi7WxhMcftt YSqm7gZlARxkwnE+Zleb4nNrIOQLzOOIQZ2/oWZ5/uL172k7lu0msbNfHt/M28XofPlq vblSPxb8JzuKbwsAF8W1IJJCXK3u3qXGV5nlyUytaff1jg56+zLnfWmJl+8EBRXSHl1X oClw== X-Gm-Message-State: ACrzQf1bVUDcdmfECgqrdSjVfUOLCKIJRBL8yMdPiqQbW+ljsgPP0+IR wZrsA3VKLGydsXK9oem+seOxOoWrX+BeKWO2VOt4AqTDIeJTJYHYohOtEDIlC6H8YRt34MaQx4M zEfLftYfcYmDwC2UCyp3bI+32 X-Received: by 2002:a05:6402:379:b0:450:dc5c:f536 with SMTP id s25-20020a056402037900b00450dc5cf536mr15713179edw.298.1663593655493; Mon, 19 Sep 2022 06:20:55 -0700 (PDT) X-Google-Smtp-Source: AMsMyM769VhH9Ku3KP+FHMxt8AEvuX3TK5FYd3+2H7UhJ2/p7rIGwNNqM0Ah27nVjjauTwJTTEotvQ== X-Received: by 2002:a05:6402:379:b0:450:dc5c:f536 with SMTP id s25-20020a056402037900b00450dc5cf536mr15713162edw.298.1663593655264; Mon, 19 Sep 2022 06:20:55 -0700 (PDT) Received: from [10.39.192.161] (5920ab7b.static.cust.trined.nl. [89.32.171.123]) by smtp.gmail.com with ESMTPSA id s25-20020aa7cb19000000b004531b137e4bsm9551948edt.67.2022.09.19.06.20.54 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 19 Sep 2022 06:20:54 -0700 (PDT) From: Eelco Chaudron To: Nathan Huckleberry Cc: Dan Carpenter , llvm@lists.linux.dev, Pravin B Shelar , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Nathan Chancellor , Nick Desaulniers , Tom Rix , netdev@vger.kernel.org, dev@openvswitch.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] openvswitch: Change the return type for vport_ops.send function hook to int Date: Mon, 19 Sep 2022 15:20:53 +0200 X-Mailer: MailMate (1.14r5915) Message-ID: <1A1ECEC1-5CCE-4D86-A116-D291C88743C0@redhat.com> In-Reply-To: <20220913230739.228313-1-nhuck@google.com> References: <20220913230739.228313-1-nhuck@google.com> MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 14 Sep 2022, at 1:07, Nathan Huckleberry wrote: > All usages of the vport_ops struct have the .send field set to > dev_queue_xmit or internal_dev_recv. Since most usages are set to > dev_queue_xmit, the function hook should match the signature of > dev_queue_xmit. > > The only call to vport_ops->send() is in net/openvswitch/vport.c and it > throws away the return value. > > This mismatched return type breaks forward edge kCFI since the underlying > function definition does not match the function hook definition. > > Reported-by: Dan Carpenter > Link: https://github.com/ClangBuiltLinux/linux/issues/1703 > Cc: llvm@lists.linux.dev > Signed-off-by: Nathan Huckleberry The changes look good to me. Acked-by: Eelco Chaudron