* [PATCH] Bluetooth: Remove unnecessary NULL check before vfree()
@ 2023-08-07 2:32 Ziyang Xuan
2023-08-07 3:16 ` bluez.test.bot
2023-08-07 22:50 ` [PATCH] " patchwork-bot+bluetooth
0 siblings, 2 replies; 3+ messages in thread
From: Ziyang Xuan @ 2023-08-07 2:32 UTC (permalink / raw)
To: marcel, johan.hedberg, luiz.dentz, linux-bluetooth; +Cc: william.xuanziyang
Get a coccinelle warning as follows:
net/bluetooth/coredump.c:104:2-7: WARNING: NULL check before some freeing functions is not needed.
Remove the unnecessary NULL check.
Signed-off-by: Ziyang Xuan <william.xuanziyang@huawei.com>
---
net/bluetooth/coredump.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/net/bluetooth/coredump.c b/net/bluetooth/coredump.c
index d2d2624ec708..ec97a4bab1c9 100644
--- a/net/bluetooth/coredump.c
+++ b/net/bluetooth/coredump.c
@@ -100,8 +100,7 @@ void hci_devcd_reset(struct hci_dev *hdev)
/* Call with hci_dev_lock only. */
static void hci_devcd_free(struct hci_dev *hdev)
{
- if (hdev->dump.head)
- vfree(hdev->dump.head);
+ vfree(hdev->dump.head);
hci_devcd_reset(hdev);
}
--
2.25.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* RE: Bluetooth: Remove unnecessary NULL check before vfree()
2023-08-07 2:32 [PATCH] Bluetooth: Remove unnecessary NULL check before vfree() Ziyang Xuan
@ 2023-08-07 3:16 ` bluez.test.bot
2023-08-07 22:50 ` [PATCH] " patchwork-bot+bluetooth
1 sibling, 0 replies; 3+ messages in thread
From: bluez.test.bot @ 2023-08-07 3:16 UTC (permalink / raw)
To: linux-bluetooth, william.xuanziyang
[-- Attachment #1: Type: text/plain, Size: 2338 bytes --]
This is automated email and please do not reply to this email!
Dear submitter,
Thank you for submitting the patches to the linux bluetooth mailing list.
This is a CI test results with your patch series:
PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=773474
---Test result---
Test Summary:
CheckPatch PASS 0.71 seconds
GitLint FAIL 0.56 seconds
SubjectPrefix PASS 0.10 seconds
BuildKernel PASS 43.73 seconds
CheckAllWarning PASS 46.79 seconds
CheckSparse PASS 54.08 seconds
CheckSmatch PASS 145.77 seconds
BuildKernel32 PASS 41.48 seconds
TestRunnerSetup PASS 641.68 seconds
TestRunner_l2cap-tester PASS 31.51 seconds
TestRunner_iso-tester PASS 85.57 seconds
TestRunner_bnep-tester PASS 14.37 seconds
TestRunner_mgmt-tester FAIL 257.97 seconds
TestRunner_rfcomm-tester PASS 21.70 seconds
TestRunner_sco-tester PASS 24.16 seconds
TestRunner_ioctl-tester PASS 24.67 seconds
TestRunner_mesh-tester PASS 18.26 seconds
TestRunner_smp-tester PASS 19.38 seconds
TestRunner_userchan-tester PASS 15.55 seconds
IncrementalBuild PASS 39.32 seconds
Details
##############################
Test: GitLint - FAIL
Desc: Run gitlint
Output:
Bluetooth: Remove unnecessary NULL check before vfree()
WARNING: I3 - ignore-body-lines: gitlint will be switching from using Python regex 'match' (match beginning) to 'search' (match anywhere) semantics. Please review your ignore-body-lines.regex option accordingly. To remove this warning, set general.regex-style-search=True. More details: https://jorisroovers.github.io/gitlint/configuration/#regex-style-search
4: B1 Line exceeds max length (98>80): "net/bluetooth/coredump.c:104:2-7: WARNING: NULL check before some freeing functions is not needed."
##############################
Test: TestRunner_mgmt-tester - FAIL
Desc: Run mgmt-tester with test-runner
Output:
Total: 497, Passed: 496 (99.8%), Failed: 1, Not Run: 0
Failed Test Cases
LL Privacy - Unpair 1 Timed out 2.067 seconds
---
Regards,
Linux Bluetooth
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Bluetooth: Remove unnecessary NULL check before vfree()
2023-08-07 2:32 [PATCH] Bluetooth: Remove unnecessary NULL check before vfree() Ziyang Xuan
2023-08-07 3:16 ` bluez.test.bot
@ 2023-08-07 22:50 ` patchwork-bot+bluetooth
1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+bluetooth @ 2023-08-07 22:50 UTC (permalink / raw)
To: Ziyang Xuan; +Cc: marcel, johan.hedberg, luiz.dentz, linux-bluetooth
Hello:
This patch was applied to bluetooth/bluetooth-next.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:
On Mon, 7 Aug 2023 10:32:06 +0800 you wrote:
> Get a coccinelle warning as follows:
> net/bluetooth/coredump.c:104:2-7: WARNING: NULL check before some freeing functions is not needed.
>
> Remove the unnecessary NULL check.
>
> Signed-off-by: Ziyang Xuan <william.xuanziyang@huawei.com>
>
> [...]
Here is the summary with links:
- Bluetooth: Remove unnecessary NULL check before vfree()
https://git.kernel.org/bluetooth/bluetooth-next/c/1ec3506d79fd
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-08-07 22:50 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-07 2:32 [PATCH] Bluetooth: Remove unnecessary NULL check before vfree() Ziyang Xuan
2023-08-07 3:16 ` bluez.test.bot
2023-08-07 22:50 ` [PATCH] " patchwork-bot+bluetooth
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox