All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] mm/hugetlb: Make is_aligned_hugepage_range static
@ 2020-10-29  2:13 Zou Wei
  2020-11-06 10:53 ` Thomas Bogendoerfer
  0 siblings, 1 reply; 2+ messages in thread
From: Zou Wei @ 2020-10-29  2:13 UTC (permalink / raw
  To: tsbogend; +Cc: linux-mips, linux-kernel, Zou Wei

Fix the following sparse warning:

arch/mips/mm/hugetlbpage.c:64:5: warning:
symbol 'is_aligned_hugepage_range' was not declared. Should it be static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Zou Wei <zou_wei@huawei.com>
---
 arch/mips/mm/hugetlbpage.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/mips/mm/hugetlbpage.c b/arch/mips/mm/hugetlbpage.c
index 77ffece..774c988 100644
--- a/arch/mips/mm/hugetlbpage.c
+++ b/arch/mips/mm/hugetlbpage.c
@@ -61,7 +61,7 @@ pte_t *huge_pte_offset(struct mm_struct *mm, unsigned long addr,
 /*
  * This function checks for proper alignment of input addr and len parameters.
  */
-int is_aligned_hugepage_range(unsigned long addr, unsigned long len)
+static int is_aligned_hugepage_range(unsigned long addr, unsigned long len)
 {
 	if (len & ~HPAGE_MASK)
 		return -EINVAL;
-- 
2.6.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH -next] mm/hugetlb: Make is_aligned_hugepage_range static
  2020-10-29  2:13 [PATCH -next] mm/hugetlb: Make is_aligned_hugepage_range static Zou Wei
@ 2020-11-06 10:53 ` Thomas Bogendoerfer
  0 siblings, 0 replies; 2+ messages in thread
From: Thomas Bogendoerfer @ 2020-11-06 10:53 UTC (permalink / raw
  To: Zou Wei; +Cc: linux-mips, linux-kernel

On Thu, Oct 29, 2020 at 10:13:20AM +0800, Zou Wei wrote:
> Fix the following sparse warning:
> 
> arch/mips/mm/hugetlbpage.c:64:5: warning:
> symbol 'is_aligned_hugepage_range' was not declared. Should it be static?
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Zou Wei <zou_wei@huawei.com>
> ---
>  arch/mips/mm/hugetlbpage.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/mips/mm/hugetlbpage.c b/arch/mips/mm/hugetlbpage.c
> index 77ffece..774c988 100644
> --- a/arch/mips/mm/hugetlbpage.c
> +++ b/arch/mips/mm/hugetlbpage.c
> @@ -61,7 +61,7 @@ pte_t *huge_pte_offset(struct mm_struct *mm, unsigned long addr,
>  /*
>   * This function checks for proper alignment of input addr and len parameters.
>   */
> -int is_aligned_hugepage_range(unsigned long addr, unsigned long len)
> +static int is_aligned_hugepage_range(unsigned long addr, unsigned long len)

this should give then a warning that 'is_aligned_hugepage_range' is unused.
Could you send a patch, which remove function completely ?

Thomas.

-- 
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea.                                                [ RFC1925, 2.3 ]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-11-06 10:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-10-29  2:13 [PATCH -next] mm/hugetlb: Make is_aligned_hugepage_range static Zou Wei
2020-11-06 10:53 ` Thomas Bogendoerfer

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.