Skip to contentSkip to conversation

efi_loader: Mark a function static

PATCH In review Andy Shevchenko 4 participants 8 messages Oct 21, 2024 – Oct 24, 2024

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 efi_loader: Mark a function static

efi_bootmgr_release_uridp_resource() is not used anywhere except the same file where it is defined. Mark it static. This helps avoiding the compiler warning:

lib/efi_loader/efi_bootmgr.c:388:14: warning: no previous prototype for ‘efi_bootmgr_release_uridp_resource’ [-Wmissing-prototypes]

---
 lib/efi_loader/efi_bootmgr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/efi_loader/efi_bootmgr.c +1 -1
index 589d3996b680..79144962cd73 100644
@@ -385,7 +385,7 @@ err:
  * @ctx:	event context
  * Return:	status code
  */
-efi_status_t efi_bootmgr_release_uridp_resource(struct uridp_context *ctx)
+static efi_status_t efi_bootmgr_release_uridp_resource(struct uridp_context *ctx)
 {
 	efi_status_t ret = EFI_SUCCESS;
 
Signature · 1 line
2.43.0.rc1.1336.g36b5255a03ac
Reviewed-by on v1 1/1
#1 lore raw

Thanks Andy

Quoted 26 lines · Andy Shevchenko

efi_bootmgr_release_uridp_resource() is not used anywhere except the same file where it is defined. Mark it static. This helps avoiding the compiler warning:

lib/efi_loader/efi_bootmgr.c:388:14: warning: no previous prototype for ‘efi_bootmgr_release_uridp_resource’ [-Wmissing-prototypes]

---
 lib/efi_loader/efi_bootmgr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/efi_loader/efi_bootmgr.c +1 -2
index 589d3996b680..79144962cd73 100644
@@ -385,7 +385,7 @@ err:
  * @ctx:       event context
  * Return:     status code
  */
-efi_status_t efi_bootmgr_release_uridp_resource(struct uridp_context *ctx)
+static efi_status_t efi_bootmgr_release_uridp_resource(struct uridp_context *ctx)
 {
        efi_status_t ret = EFI_SUCCESS;
 
--
Quoted 2 lines

2.43.0.rc1.1336.g36b5255a03ac

#2 lore raw
Quoted 29 lines · Ilias Apalodimas

Thanks Andy

Quoted 25 lines · Andy Shevchenko

efi_bootmgr_release_uridp_resource() is not used anywhere except the same file where it is defined. Mark it static. This helps avoiding the compiler warning:

lib/efi_loader/efi_bootmgr.c:388:14: warning: no previous prototype for ‘efi_bootmgr_release_uridp_resource’ [-Wmissing-prototypes]

---
  lib/efi_loader/efi_bootmgr.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
lib/efi_loader/efi_bootmgr.c +1 -1
index 589d3996b680..79144962cd73 100644
@@ -385,7 +385,7 @@ err:
   * @ctx:       event context
   * Return:     status code
   */
-efi_status_t efi_bootmgr_release_uridp_resource(struct uridp_context *ctx)
+static efi_status_t efi_bootmgr_release_uridp_resource(struct uridp_context *ctx)
  {
         efi_status_t ret = EFI_SUCCESS;
 
Quoted 5 lines
Quoted 3 lines

--
2.43.0.rc1.1336.g36b5255a03ac

Hello Andy,

The function is called efi_bootmgr_release_uridp() since 292a4a4c7b77 ("efi_loader: shorten efi_bootmgr_release_uridp_resource()").

Best regards

Heinrich

#3 lore raw
Quoted 4 lines · Heinrich Schuchardt
Quoted 3 lines · Ilias Apalodimas
Quoted 1 line · Andy Shevchenko
Quoted 8 lines
Quoted 5 lines
Quoted 5 lines

efi_bootmgr_release_uridp_resource() is not used anywhere except the same file where it is defined. Mark it static. This helps avoiding the compiler warning:

lib/efi_loader/efi_bootmgr.c:388:14: warning: no previous prototype for ‘efi_bootmgr_release_uridp_resource’ [-Wmissing-prototypes]

The function is called efi_bootmgr_release_uridp() since 292a4a4c7b77 ("efi_loader: shorten efi_bootmgr_release_uridp_resource()").

Thanks! The problem is that U-Boot doesn't have the latest tag (yet) that includes this change. You can help with managing the conflict.

Signature · 2 lines
With Best Regards,
Andy Shevchenko
#4 lore raw

Am 22. Oktober 2024 15:18:45 MESZ schrieb Andy Shevchenko <[email protected]>:

Quoted 9 lines · Heinrich Schuchardt
Quoted 8 lines · Ilias Apalodimas
Quoted 7 lines
Quoted 5 lines · Andy Shevchenko

efi_bootmgr_release_uridp_resource() is not used anywhere except the same file where it is defined. Mark it static. This helps avoiding the compiler warning:

Quoted 8 lines
Quoted 4 lines
Quoted 1 line
Quoted 1 line

lib/efi_loader/efi_bootmgr.c:388:14: warning: no previous prototype for ‘efi_bootmgr_release_uridp_resource’ [-Wmissing-prototypes]

The function is called efi_bootmgr_release_uridp() since 292a4a4c7b77 ("efi_loader: shorten efi_bootmgr_release_uridp_resource()").

Thanks! The problem is that U-Boot doesn't have the latest tag (yet) that includes this change. You can help with managing the conflict.

Patches should be based on origin/master (or origin/next once that branch is opened typically after -rc2) and not on tags.

Best regards

Heinrich

#5 lore raw
Quoted 12 lines · Heinrich Schuchardt

Am 22. Oktober 2024 15:18:45 MESZ schrieb Andy Shevchenko <[email protected]>:

Quoted 11 lines · Heinrich Schuchardt
Quoted 9 lines · Ilias Apalodimas
Quoted 8 lines
Quoted 6 lines · Andy Shevchenko

efi_bootmgr_release_uridp_resource() is not used anywhere except the same file where it is defined. Mark it static. This helps avoiding the compiler warning:

lib/efi_loader/efi_bootmgr.c:388:14: warning: no previous prototype for ‘efi_bootmgr_release_uridp_resource’ [-Wmissing-prototypes]

Quoted 8 lines
Quoted 5 lines
Quoted 2 lines

The function is called efi_bootmgr_release_uridp() since 292a4a4c7b77 ("efi_loader: shorten efi_bootmgr_release_uridp_resource()").

Thanks! The problem is that U-Boot doesn't have the latest tag (yet) that includes this change. You can help with managing the conflict.

Patches should be based on origin/master (or origin/next once that branch is opened typically after -rc2) and not on tags.

I disagree. The problem with moving target that it's been moving...

The tags are very good to follow and easy to maintain and test and report regressions against. What you are suggesting it's like virtually assigning tag to very each commit and tell maintainer to cope with this chaos when one does something in one "tag" out of 100500 ones and another person in another "tag". So, consider tags as stabilisation points, or points of stability. Then it's much easier to stick with a few tags that with 100500 commits.

Signature · 2 lines
With Best Regards,
Andy Shevchenko
#6 lore raw
Quoted 24 lines · Andy Shevchenko
Quoted 12 lines · Heinrich Schuchardt

Am 22. Oktober 2024 15:18:45 MESZ schrieb Andy Shevchenko <[email protected]>:

Quoted 11 lines · Heinrich Schuchardt
Quoted 9 lines · Ilias Apalodimas
Quoted 8 lines
Quoted 6 lines · Andy Shevchenko

efi_bootmgr_release_uridp_resource() is not used anywhere except the same file where it is defined. Mark it static. This helps avoiding the compiler warning:

lib/efi_loader/efi_bootmgr.c:388:14: warning: no previous prototype for ‘efi_bootmgr_release_uridp_resource’ [-Wmissing-prototypes]

Quoted 8 lines
Quoted 5 lines
Quoted 2 lines

The function is called efi_bootmgr_release_uridp() since 292a4a4c7b77 ("efi_loader: shorten efi_bootmgr_release_uridp_resource()").

Thanks! The problem is that U-Boot doesn't have the latest tag (yet) that includes this change. You can help with managing the conflict.

Patches should be based on origin/master (or origin/next once that branch is opened typically after -rc2) and not on tags.

I disagree. The problem with moving target that it's been moving...

Quoted 7 lines

The tags are very good to follow and easy to maintain and test and report regressions against. What you are suggesting it's like virtually assigning tag to very each commit and tell maintainer to cope with this chaos when one does something in one "tag" out of 100500 ones and another person in another "tag". So, consider tags as stabilisation points, or points of stability. Then it's much easier to stick with a few tags that with 100500 commits.

This isn't the linux kernel where there's constant churn. Most of the time, it doesn't matter at all. Sometimes it does. Then it's a question of if the custodian wants to do the rebase work themselves, or ask the submitter to. And since again unlike the kernel almost no one has the primary job of "work on U-Boot", the threshold for fixup or ask for a rebase is much lower.

Signature · 1 line
Tom
#7 lore raw
Quoted 33 lines · Tom Rini
Quoted 24 lines · Andy Shevchenko
Quoted 12 lines · Heinrich Schuchardt

Am 22. Oktober 2024 15:18:45 MESZ schrieb Andy Shevchenko <[email protected]>:

Quoted 11 lines · Heinrich Schuchardt
Quoted 9 lines · Ilias Apalodimas
Quoted 8 lines
Quoted 6 lines · Andy Shevchenko

efi_bootmgr_release_uridp_resource() is not used anywhere except the same file where it is defined. Mark it static. This helps avoiding the compiler warning:

lib/efi_loader/efi_bootmgr.c:388:14: warning: no previous prototype for ‘efi_bootmgr_release_uridp_resource’ [-Wmissing-prototypes]

Quoted 8 lines
Quoted 5 lines
Quoted 2 lines

The function is called efi_bootmgr_release_uridp() since 292a4a4c7b77 ("efi_loader: shorten efi_bootmgr_release_uridp_resource()").

Thanks! The problem is that U-Boot doesn't have the latest tag (yet) that includes this change. You can help with managing the conflict.

Patches should be based on origin/master (or origin/next once that branch is opened typically after -rc2) and not on tags.

I disagree. The problem with moving target that it's been moving...

Quoted 7 lines

The tags are very good to follow and easy to maintain and test and report regressions against. What you are suggesting it's like virtually assigning tag to very each commit and tell maintainer to cope with this chaos when one does something in one "tag" out of 100500 ones and another person in another "tag". So, consider tags as stabilisation points, or points of stability. Then it's much easier to stick with a few tags that with 100500 commits.

Quoted 6 lines

This isn't the linux kernel where there's constant churn. Most of the time, it doesn't matter at all. Sometimes it does. Then it's a question of if the custodian wants to do the rebase work themselves, or ask the submitter to. And since again unlike the kernel almost no one has the primary job of "work on U-Boot", the threshold for fixup or ask for a rebase is much lower.

I see your point, thanks for elaboration. Although I think even taking it into account the Linux kernel approach makes some process, which is stable (more or less) and understandable by many. I feel uncomfortable to rebase on top of random commit. I also have scripts to update my branches and the proposed approach breaks this badly. So I prefer to stick with my flow. That said, consider the patch as reported problem by me. I will help testing any new tag that will have a respective fix, or fix separately based on the tag, so I won't need a special commits on top of.

Signature · 2 lines
With Best Regards,
Andy Shevchenko