public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 2.6] clean-up: fixes "shadows global" warning
@ 2004-12-06 20:52 Riina Kikas
  2004-12-06 21:41 ` Adrian Bunk
  0 siblings, 1 reply; 4+ messages in thread
From: Riina Kikas @ 2004-12-06 20:52 UTC (permalink / raw)
  To: linux-kernel; +Cc: mroos

This patch fixes warning "declaration of `errno' shadows a global declaration"
occuring on line 102

Signed-off-by: Riina Kikas <Riina.Kikas@mail.ee>

--- a/include/linux/nfsd/export.h	2004-08-14 10:55:33.000000000 +0000
+++ b/include/linux/nfsd/export.h	2004-10-31 19:01:15.000000000 +0000
@@ -99,7 +99,7 @@
  int			exp_rootfh(struct auth_domain *,
  					char *path, struct knfsd_fh *, int maxsize);
  int			exp_pseudoroot(struct auth_domain *, struct svc_fh *fhp, struct cache_req *creq);
-int			nfserrno(int errno);
+int			nfserrno(int errno_l);

  extern void expkey_put(struct cache_head *item, struct cache_detail *cd);
  extern void svc_export_put(struct cache_head *item, struct cache_detail *cd);

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

* [PATCH 2.6] clean-up: fixes "shadows global" warning
@ 2004-12-06 21:00 Riina Kikas
  0 siblings, 0 replies; 4+ messages in thread
From: Riina Kikas @ 2004-12-06 21:00 UTC (permalink / raw)
  To: linux-kernel; +Cc: mroos

This patch fixes warning "declaration of `index' shadows a global declaration"
occuring on line 384

Signed-off-by: Riina Kikas <Riina.Kikas@mail.ee>

--- a/mm/swap.c	2004-08-14 10:55:19.000000000 +0000
+++ b/mm/swap.c	2004-12-02 20:56:43.000000000 +0000
@@ -381,9 +381,9 @@
  }

  unsigned pagevec_lookup_tag(struct pagevec *pvec, struct address_space *mapping,
-		pgoff_t *index, int tag, unsigned nr_pages)
+		pgoff_t *asc_index, int tag, unsigned nr_pages)
  {
-	pvec->nr = find_get_pages_tag(mapping, index, tag,
+	pvec->nr = find_get_pages_tag(mapping, asc_index, tag,
  					nr_pages, pvec->pages);
  	return pagevec_count(pvec);
  }

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

* [PATCH 2.6] clean-up: fixes "shadows global" warning
@ 2004-12-06 21:01 Riina Kikas
  0 siblings, 0 replies; 4+ messages in thread
From: Riina Kikas @ 2004-12-06 21:01 UTC (permalink / raw)
  To: linux-kernel; +Cc: mroos

This patch fixes warning "declaration of `jiffies' shadows a global declaration"
occuring on line 236

Signed-off-by: Riina Kikas <Riina.Kikas@mail.ee>

--- a/include/linux/time.h	2004-08-14 10:55:35.000000000 +0000
+++ b/include/linux/time.h	2004-12-02 21:16:18.000000000 +0000
@@ -233,13 +233,13 @@
  }

  static __inline__ void
-jiffies_to_timespec(const unsigned long jiffies, struct timespec *value)
+jiffies_to_timespec(const unsigned long jiffy_count, struct timespec *value)
  {
  	/*
  	 * Convert jiffies to nanoseconds and separate with
  	 * one divide.
  	 */
-	u64 nsec = (u64)jiffies * TICK_NSEC; 
+	u64 nsec = (u64)jiffy_count * TICK_NSEC;
  	value->tv_sec = div_long_long_rem(nsec, NSEC_PER_SEC, &value->tv_nsec);
  }


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

* Re: [PATCH 2.6] clean-up: fixes "shadows global" warning
  2004-12-06 20:52 [PATCH 2.6] clean-up: fixes "shadows global" warning Riina Kikas
@ 2004-12-06 21:41 ` Adrian Bunk
  0 siblings, 0 replies; 4+ messages in thread
From: Adrian Bunk @ 2004-12-06 21:41 UTC (permalink / raw)
  To: Riina Kikas; +Cc: linux-kernel, mroos

On Mon, Dec 06, 2004 at 10:52:58PM +0200, Riina Kikas wrote:
> This patch fixes warning "declaration of `errno' shadows a global 
> declaration"
> occuring on line 102
> 
> Signed-off-by: Riina Kikas <Riina.Kikas@mail.ee>
> 
> --- a/include/linux/nfsd/export.h	2004-08-14 10:55:33.000000000 +0000
> +++ b/include/linux/nfsd/export.h	2004-10-31 19:01:15.000000000 +0000
> @@ -99,7 +99,7 @@
>  int			exp_rootfh(struct auth_domain *,
>  					char *path, struct knfsd_fh *, int 
>  					maxsize);
>  int			exp_pseudoroot(struct auth_domain *, struct svc_fh 
>  *fhp, struct cache_req *creq);
> -int			nfserrno(int errno);
> +int			nfserrno(int errno_l);
> 
>  extern void expkey_put(struct cache_head *item, struct cache_detail *cd);
>  extern void svc_export_put(struct cache_head *item, struct cache_detail 
>  *cd);

It doesn't make much sense to change the name in the prototype in the 
header file but not in the actual file.

cu
Adrian

-- 

       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed


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

end of thread, other threads:[~2004-12-06 21:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-12-06 20:52 [PATCH 2.6] clean-up: fixes "shadows global" warning Riina Kikas
2004-12-06 21:41 ` Adrian Bunk
  -- strict thread matches above, loose matches on Subject: below --
2004-12-06 21:00 Riina Kikas
2004-12-06 21:01 Riina Kikas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox