>> …
>>> +++ b/include/net/devmem.h
>>> @@ -0,0 +1,115 @@
>> …
>>> +#ifndef _NET_DEVMEM_H
>>> +#define _NET_DEVMEM_H
>> …
>>
>> I suggest to omit leading underscores from such identifiers.
>> https://wiki.sei.cmu.edu/confluence/display/c/DCL37-C.+Do+not+declare+or+define+a+reserved+identifier
>>
>
…
> +++ b/include/net/devmem.h
> @@ -0,0 +1,115 @@
…
> +#ifndef _NET_DEVMEM_H
> +#define _NET_DEVMEM_H
…
I suggest to omit leading underscores from such identifiers.
https://wiki.sei.cmu.edu/confluence/display/c/DCL37-C.+Do+not+declare+or+define+a+reserved+identifier
Regards,
Markus
> The format specifier in fprintf is "%u", that "%u" should use
> unsigned int type instead.
* Please improve the change description with imperative wordings.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v6.10#n94
* Woul
> The requested resources should be closed before return in main(), otherwise
> resource leak will occur. Add a check of cg_fd before close().
>
> Fixes: 435f90a338ae ("selftests/bpf: add a test case for sock_ops perf-event
> notification")
> Signed-off-by: Ma Ke
Please reconsider such informati
>… openat() and open() initialize
> 'from' and 'to', and only 'from' validated with 'if' statement.
Why do you find such information helpful?
> If the
> initialization of variable 'to' fails,
>… openat() and open() initialize
> 'from' and 'to', and only 'from' validated with 'if' statement.
Why do you find such information helpful?
> If the
> initialization of variable 'to' fails,
>… openat() and open() initialize
> 'from' and 'to', and only 'from' validated with 'if' statement.
Why do find such information helpful?
> If the
> initialization of variable 'to' fails,
The
…
> +++ b/net/core/netdev-genl.c
…
> int netdev_nl_bind_rx_doit(struct sk_buff *skb, struct genl_info *info)
> {
…
> + rtnl_lock();
> +
> + netdev = __dev_get_by_index(genl_info_net(info), ifindex);
…
> +err_unlock:
> + rtnl_unlock();
> + return err;
> }
…
Would you become inter
> There is a 'malloc' call, which can be unsuccessful.
two calls?
> This patch will add the malloc failure checking
…
Please use imperative wordings for improved change descriptions also in your
patches.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/
> This is already done in main.
Please improve this change description.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v6.9-rc6#n45
Will the tag “Fixes” become relevant here (besides an imperative wording)?
Regards,
Markus
> > There is a 'malloc' call, which can be unsuccessful.
> > This patch will add the malloc failure checking
> > to avoid possible null dereference and give more information
> > about test fail reasons.
>
> Applied to arm64 (for-next/selftests), thanks!
>
> [1/1] kselftest: arm64: Add a null pointe
…
> Add the malloc failure checking to avoid possible null
> dereference.
…
How do you think about to use the following wording variant?
Add a return value check so that a null pointer dereference will be avoided
after a memory allocation failure.
Would you like to add the tag “Fixes” acc
…
> Add the malloc failure checking to avoid possible null
> dereference.
…
How do you think about the following wording variant?
Add a return value check so that a null pointer dereference will be avoided
after a memory allocation failure.
Would you like to add the tag “Fixes” accordingl
…
> This patch will add the malloc failure checking
…
* Please use a corresponding imperative wording for the change description.
* Would you like to add the tag “Fixes” accordingly?
Regards,
Markus
…
> This patch will add the malloc failure checking
…
* Please use a corresponding imperative wording for the change description.
* Would you like to add the tag “Fixes” accordingly?
…
> +++ b/tools/testing/selftests/bpf/test_progs.c
> @@ -582,6 +582,11 @@ int compare_stack_ips(int smap_fd, int
…
> This patch will add the malloc failure checking
…
* Please use a corresponding imperative wording for the change description.
* Would you like to add the tag “Fixes” accordingly?
…
> +++ b/tools/testing/selftests/kvm/get-reg-list.c
> @@ -66,6 +66,7 @@ static const char *config_name(struct v
…
> This patch will add the malloc failure checking
…
* Please use a corresponding imperative wording for the change description.
* Would you like to add the tag “Fixes” accordingly?
…
> +++ b/tools/testing/selftests/kvm/x86_64/vmx_set_nested_state_test.c
> @@ -91,6 +91,7 @@ void test_vmx_neste
…
> This patch will add the malloc failure checking
…
* Please use a corresponding imperative wording for the change description.
* Would you like to add the tag “Fixes” accordingly?
Regards,
Markus
> > kunit_init_device() should unregister the device on bus register error,
> > but mistakenly it tries to unregister the bus.
> >
> > Unregister the device instead of the bus.
…
> Reviewed-by: Greg Kroah-Hartman
Would you ever like to distinguish hardware register errors from
item registration f
…
> * Remove some changes requested by Marcus Elfring,
I became curious how affected software components can evolve further.
> as I was alerted he is a known troll.
I would appreciate if this interpretation will be reconsidered somehow.
Regards,
Markus
> If the device register fails, free the allocated memory before
> returning.
Can a description variant (like the following) be more appropriate?
Free the allocated memory (after a device registration failure)
before returning.
Thus add a jump target so that a bit of exception handling c
> kunit_init_device() should unregister the device on bus register error,
> but mistakenly it tries to unregister the bus.
Would the following description variant be more appropriate?
kunit_init_device() should unregister the device on bus registration error.
But it mistakenly tries to unre
>> Common error handling code can be used instead
>> if an additional label would be applied for a corresponding jump target.
>>
>> How do you think about to increase the application of scope-based resource
>> management here?
>
> I thought about that. But I think the code is simple enough (for no
> If the device register fails, free the allocated memory before
> returning.
* I suggest to use the word “registration” (instead of “register”)
in the commit message.
* Would you like to add the tag “Fixes” accordingly?
> +++ b/lib/kunit/device.c
> @@ -131,6 +131,7 @@ static struct kunit_dev
> kunit_init_device() should unregister the device on bus register error.
* Would another imperative wording be desirable also for this change
description?
* Will the tag “Fixes” become relevant here?
Regards,
Markus
25 matches
Mail list logo