From: Dan Carpenter <dan.carpenter@oracle.com>
To: Phillip Potter <phil@philpotter.co.uk>
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
Date: Wed, 3 Aug 2022 15:11:08 +0300 [thread overview]
Message-ID: <20220803121108.GC3438@kadam> (raw)
In-Reply-To: <20220802234408.930-1-phil@philpotter.co.uk>
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 <phil@philpotter.co.uk>
Looks good. Thanks!
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
regards,
dan carpenter
next prev parent reply other threads:[~2022-08-03 12:11 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-02 23:44 [PATCH] staging: r8188eu: convert rtw_p2p_enable to correct error code semantics Phillip Potter
2022-08-03 12:11 ` Dan Carpenter [this message]
2022-08-04 22:35 ` Phillip Potter
2022-08-04 20:26 ` Philipp Hortmann
2022-08-04 22:37 ` Phillip Potter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220803121108.GC3438@kadam \
--to=dan.carpenter@oracle.com \
--cc=Larry.Finger@lwfinger.net \
--cc=abdun.nihaal@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=martin@kaiser.cx \
--cc=paskripkin@gmail.com \
--cc=phil@philpotter.co.uk \
--cc=straube.linux@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox