Received: by 2002:a05:6358:e9c4:b0:b2:91dc:71ab with SMTP id hc4csp1020741rwb; Thu, 4 Aug 2022 15:46:33 -0700 (PDT) X-Google-Smtp-Source: AA6agR6uY6Q8NeaPuBOc3K5XqK+e3N5nRT1HVQoZI2N9qpDU6l40E5NrcwYJFOdlZp9PzODyJwZu X-Received: by 2002:a05:6402:254b:b0:43e:7c6a:f431 with SMTP id l11-20020a056402254b00b0043e7c6af431mr4094975edb.305.1659653193244; Thu, 04 Aug 2022 15:46:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659653193; cv=none; d=google.com; s=arc-20160816; b=uKmVAPk3AfL7oQiGGT4YkXbRhXq4XdVo60s5FF+BZPJsh4y7fvUbYVbyezaOLRfK0G dn36y7PveonqMzsXnAOLSJsrWMv0L7AjbL48/2qoqEgI3IV8/MXgOl4TNANvT91frhZ7 fm8x/pVNcxlCbay0dM6bqlq8G4uCXb8hugdf3o1y2kZ8JM3fcnPMSzMu0Mnb5AV5qrh8 bj1rYt0FoyEJiAaA8Pd7vUBl6YNGgT6eVY7SRtm+hj536gJHHmBVftTyiMKIEt7xJhFL loxwF5LZfxKsXNXPLXKNk8MZFX1JdgONjr/qy88eM9P+OicZ/YWFvQ4OkqpgWmPaspVD P2Mw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=GjhcCM6pqUfDNnBpeTBTrm5a2+uQw6A9z6WoPf0/fPw=; b=XeXeYPleHPMIxJaY3/Z53MTpCMEgdrkaqWsRnFKMryuwa/iUH5j2HzmH4EU6UVXvts O+9bCIOe8kVV0N+PHg8WlVbEk5VFWgnb6OXAy71dsFihDQpJHVL4O1Q5cBECaV/KbY0f GZdA9cSrOs3gaWax1id9cyr+/dws2eAEH0rOlEvv575HTX/wc5h8NnSqNH2yknW0s3MB LLPXPv9eV/Y9Dqta/+zO82fkzKDXBUnJ5D62GlwLSGeTXZ1YgftTaDrBRjaOEeF61uPH 31Ziu0v3+GO14SUz10U4oiN9MDJO4rjSA+WVxN18NpJlMkc9ZJtfPcvfL58iBqGCajZk /Q4w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@philpotter-co-uk.20210112.gappssmtp.com header.s=20210112 header.b=t8yThKZC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k21-20020a17090666d500b0073065e93b16si1750578ejp.130.2022.08.04.15.46.07; Thu, 04 Aug 2022 15:46:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@philpotter-co-uk.20210112.gappssmtp.com header.s=20210112 header.b=t8yThKZC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239977AbiHDWf7 (ORCPT + 99 others); Thu, 4 Aug 2022 18:35:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60068 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234746AbiHDWf6 (ORCPT ); Thu, 4 Aug 2022 18:35:58 -0400 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EB2266267 for ; Thu, 4 Aug 2022 15:35:56 -0700 (PDT) Received: by mail-wm1-x330.google.com with SMTP id b21-20020a05600c4e1500b003a32bc8612fso509492wmq.3 for ; Thu, 04 Aug 2022 15:35:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=philpotter-co-uk.20210112.gappssmtp.com; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc; bh=GjhcCM6pqUfDNnBpeTBTrm5a2+uQw6A9z6WoPf0/fPw=; b=t8yThKZC3eE9v7bQ67YqGuHSMxvZqH2fBBRFYDhtuEoV1F3JD0O1o14QmFYgIsm6CP uSkYNSebUa2MyO+wnGTok5JA0h2tHKmQue4gPHuUC2Bkhbwg0nS+YQzqUVnl/gCzgo+B uiQg609+1qsh74kxhOTfp6eNHne0Nt3pDlJELke/yiGsJtssYyPH14Esvecg02IVVXGO T5fa9tdb90W431J+9vmvF6VhqxwitQ4E/yWEJ/inpw1aLrmETElvnrehnfVgdqpVKqEq uWf9/4Smth4kO6EmaGVKqcBax9qjfeXjyawh/EGCnkUPrS48lmhaitTYjaOVaxu8dhff ip0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc; bh=GjhcCM6pqUfDNnBpeTBTrm5a2+uQw6A9z6WoPf0/fPw=; b=uYyIja9NiU3RXkpdD/yJkpTbPEhRKe6zHrEoajNWBucouEgMbfMCrp5sB8zv0btIrD H8z2WKl1XcmOu3WTzf/w/8q8/t+BCZdbAFYARW3/yGXbyOwCHwLqQqkrNQSt9BWm8sao UbwbnvcRhQOycvQsWt1Z6PEZlIzVoRYQcKdKCdSHv7B8hedXHp7mX6/AVlUg4yqKDfrn 7fjixUJdocAgHDW9xir6zPVbhHZ9U2xxbXxwUv28KV/pMnBrN6nf2RVl9ooKKkVzOKsr UagvS70UwQh4GxXr6FlOX4XL3V9RLqkQ0UjBTfkjfyoWDIezYQKM9ngHQWfczl+Kos4I XvTA== X-Gm-Message-State: ACgBeo37tKhtsq358SkTYfI6tndcFWgkCn165P83Ex2oVrjpuzAX3bxt NCVaQtpCRS0QEGSdmPEc7LapMw== X-Received: by 2002:a05:600c:49a4:b0:3a5:fa7:18ef with SMTP id h36-20020a05600c49a400b003a50fa718efmr2665854wmp.156.1659652555540; Thu, 04 Aug 2022 15:35:55 -0700 (PDT) Received: from equinox (2.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.a.1.e.e.d.f.d.0.b.8.0.1.0.0.2.ip6.arpa. [2001:8b0:dfde:e1a0::2]) by smtp.gmail.com with ESMTPSA id n21-20020a05600c3b9500b003a2d6c623f3sm7619306wms.19.2022.08.04.15.35.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 04 Aug 2022 15:35:54 -0700 (PDT) Date: Thu, 4 Aug 2022 23:35:52 +0100 From: Phillip Potter To: Dan Carpenter Cc: gregkh@linuxfoundation.org, Larry.Finger@lwfinger.net, paskripkin@gmail.com, straube.linux@gmail.com, martin@kaiser.cx, abdun.nihaal@gmail.com, linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: Re: [PATCH] staging: r8188eu: convert rtw_p2p_enable to correct error code semantics Message-ID: References: <20220802234408.930-1-phil@philpotter.co.uk> <20220803121108.GC3438@kadam> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220803121108.GC3438@kadam> X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Aug 03, 2022 at 03:11:08PM +0300, Dan Carpenter wrote: > On Wed, Aug 03, 2022 at 12:44:08AM +0100, Phillip Potter wrote: > > Convert the rtw_p2p_enable function to use correct error code semantics > > rather than _SUCCESS/_FAIL, and also make sure we allow these to be > > passed through properly in the one caller where we actually check the > > code, rtw_wext_p2p_enable. > > > > This change moves these functions to a clearer 'return 0;' style at the > > end of the function, and in the case of errors now returns ret instead > > of jumping to the end of the function, so that these can still be passed > > through but without using a goto to jump to a single return statement at > > the end which is less clear. > > > > This change moves the driver slowly closer to using standard error code > > semantics everywhere. > > > > Signed-off-by: Phillip Potter > > Looks good. Thanks! > > Reviewed-by: Dan Carpenter > > regards, > dan carpenter > Thanks for the review Dan, much appreciated. Regards, Phil