CVS commit: src/sys/coda

2024-05-17 Thread Jason R Thorpe
Module Name:src
Committed By:   thorpej
Date:   Fri May 17 23:57:46 UTC 2024

Modified Files:
src/sys/coda: coda_namecache.c coda_psdev.c coda_subr.c coda_venus.c
coda_vfsops.c

Log Message:
Remove unnecessary include of .


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/sys/coda/coda_namecache.c
cvs rdiff -u -r1.64 -r1.65 src/sys/coda/coda_psdev.c
cvs rdiff -u -r1.32 -r1.33 src/sys/coda/coda_subr.c
cvs rdiff -u -r1.30 -r1.31 src/sys/coda/coda_venus.c
cvs rdiff -u -r1.90 -r1.91 src/sys/coda/coda_vfsops.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/coda/coda_namecache.c
diff -u src/sys/coda/coda_namecache.c:1.29 src/sys/coda/coda_namecache.c:1.30
--- src/sys/coda/coda_namecache.c:1.29	Fri Feb  9 22:08:34 2024
+++ src/sys/coda/coda_namecache.c	Fri May 17 23:57:46 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: coda_namecache.c,v 1.29 2024/02/09 22:08:34 andvar Exp $	*/
+/*	$NetBSD: coda_namecache.c,v 1.30 2024/05/17 23:57:46 thorpej Exp $	*/
 
 /*
  *
@@ -77,11 +77,10 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: coda_namecache.c,v 1.29 2024/02/09 22:08:34 andvar Exp $");
+__KERNEL_RCSID(0, "$NetBSD: coda_namecache.c,v 1.30 2024/05/17 23:57:46 thorpej Exp $");
 
 #include 
 #include 
-#include 
 #include 
 #include 
 

Index: src/sys/coda/coda_psdev.c
diff -u src/sys/coda/coda_psdev.c:1.64 src/sys/coda/coda_psdev.c:1.65
--- src/sys/coda/coda_psdev.c:1.64	Tue Feb 13 21:39:02 2024
+++ src/sys/coda/coda_psdev.c	Fri May 17 23:57:46 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: coda_psdev.c,v 1.64 2024/02/13 21:39:02 andvar Exp $	*/
+/*	$NetBSD: coda_psdev.c,v 1.65 2024/05/17 23:57:46 thorpej Exp $	*/
 
 /*
  *
@@ -54,14 +54,13 @@
 /* These routines are the device entry points for Venus. */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: coda_psdev.c,v 1.64 2024/02/13 21:39:02 andvar Exp $");
+__KERNEL_RCSID(0, "$NetBSD: coda_psdev.c,v 1.65 2024/05/17 23:57:46 thorpej Exp $");
 
 extern int coda_nc_initialized;/* Set if cache has been initialized */
 
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 

Index: src/sys/coda/coda_subr.c
diff -u src/sys/coda/coda_subr.c:1.32 src/sys/coda/coda_subr.c:1.33
--- src/sys/coda/coda_subr.c:1.32	Mon Apr 13 19:23:17 2020
+++ src/sys/coda/coda_subr.c	Fri May 17 23:57:46 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: coda_subr.c,v 1.32 2020/04/13 19:23:17 ad Exp $	*/
+/*	$NetBSD: coda_subr.c,v 1.33 2024/05/17 23:57:46 thorpej Exp $	*/
 
 /*
  *
@@ -55,11 +55,10 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: coda_subr.c,v 1.32 2020/04/13 19:23:17 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: coda_subr.c,v 1.33 2024/05/17 23:57:46 thorpej Exp $");
 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 

Index: src/sys/coda/coda_venus.c
diff -u src/sys/coda/coda_venus.c:1.30 src/sys/coda/coda_venus.c:1.31
--- src/sys/coda/coda_venus.c:1.30	Thu Oct 17 20:56:02 2013
+++ src/sys/coda/coda_venus.c	Fri May 17 23:57:46 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: coda_venus.c,v 1.30 2013/10/17 20:56:02 christos Exp $	*/
+/*	$NetBSD: coda_venus.c,v 1.31 2024/05/17 23:57:46 thorpej Exp $	*/
 
 /*
  *
@@ -32,11 +32,10 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: coda_venus.c,v 1.30 2013/10/17 20:56:02 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: coda_venus.c,v 1.31 2024/05/17 23:57:46 thorpej Exp $");
 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 

Index: src/sys/coda/coda_vfsops.c
diff -u src/sys/coda/coda_vfsops.c:1.90 src/sys/coda/coda_vfsops.c:1.91
--- src/sys/coda/coda_vfsops.c:1.90	Mon Mar 28 12:37:46 2022
+++ src/sys/coda/coda_vfsops.c	Fri May 17 23:57:46 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: coda_vfsops.c,v 1.90 2022/03/28 12:37:46 riastradh Exp $	*/
+/*	$NetBSD: coda_vfsops.c,v 1.91 2024/05/17 23:57:46 thorpej Exp $	*/
 
 /*
  *
@@ -45,12 +45,11 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: coda_vfsops.c,v 1.90 2022/03/28 12:37:46 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: coda_vfsops.c,v 1.91 2024/05/17 23:57:46 thorpej Exp $");
 
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 



CVS commit: src/sys/coda

2024-05-17 Thread Jason R Thorpe
Module Name:src
Committed By:   thorpej
Date:   Fri May 17 23:57:46 UTC 2024

Modified Files:
src/sys/coda: coda_namecache.c coda_psdev.c coda_subr.c coda_venus.c
coda_vfsops.c

Log Message:
Remove unnecessary include of .


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/sys/coda/coda_namecache.c
cvs rdiff -u -r1.64 -r1.65 src/sys/coda/coda_psdev.c
cvs rdiff -u -r1.32 -r1.33 src/sys/coda/coda_subr.c
cvs rdiff -u -r1.30 -r1.31 src/sys/coda/coda_venus.c
cvs rdiff -u -r1.90 -r1.91 src/sys/coda/coda_vfsops.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/coda

2024-05-17 Thread Jason R Thorpe
Module Name:src
Committed By:   thorpej
Date:   Fri May 17 23:56:24 UTC 2024

Modified Files:
src/sys/coda: cnode.h

Log Message:
 -> 


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/coda/cnode.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/coda/cnode.h
diff -u src/sys/coda/cnode.h:1.20 src/sys/coda/cnode.h:1.21
--- src/sys/coda/cnode.h:1.20	Sat Dec 13 15:59:30 2014
+++ src/sys/coda/cnode.h	Fri May 17 23:56:24 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: cnode.h,v 1.20 2014/12/13 15:59:30 hannken Exp $	*/
+/*	$NetBSD: cnode.h,v 1.21 2024/05/17 23:56:24 thorpej Exp $	*/
 
 /*
  *
@@ -49,7 +49,7 @@
 
 #include 
 #ifdef _KERNEL
-#include 
+#include 
 
 MALLOC_DECLARE(M_CODA);
 #endif



CVS commit: src/sys/coda

2024-05-17 Thread Jason R Thorpe
Module Name:src
Committed By:   thorpej
Date:   Fri May 17 23:56:24 UTC 2024

Modified Files:
src/sys/coda: cnode.h

Log Message:
 -> 


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/coda/cnode.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/coda

2023-08-02 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Thu Aug  3 03:10:23 UTC 2023

Modified Files:
src/sys/coda: coda_psdev.c

Log Message:
coda_call(): Appease GCC 12.3.0 -Wmisleading-indentation
No binary changes.


To generate a diff of this commit:
cvs rdiff -u -r1.62 -r1.63 src/sys/coda/coda_psdev.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/coda/coda_psdev.c
diff -u src/sys/coda/coda_psdev.c:1.62 src/sys/coda/coda_psdev.c:1.63
--- src/sys/coda/coda_psdev.c:1.62	Tue May  3 20:52:31 2022
+++ src/sys/coda/coda_psdev.c	Thu Aug  3 03:10:23 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: coda_psdev.c,v 1.62 2022/05/03 20:52:31 andvar Exp $	*/
+/*	$NetBSD: coda_psdev.c,v 1.63 2023/08/03 03:10:23 rin Exp $	*/
 
 /*
  *
@@ -54,7 +54,7 @@
 /* These routines are the device entry points for Venus. */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: coda_psdev.c,v 1.62 2022/05/03 20:52:31 andvar Exp $");
+__KERNEL_RCSID(0, "$NetBSD: coda_psdev.c,v 1.63 2023/08/03 03:10:23 rin Exp $");
 
 extern int coda_nc_initialized;/* Set if cache has been initialized */
 
@@ -712,9 +712,10 @@ coda_call(struct coda_mntinfo *mntinfo, 
 	}
 
 	else {	/* If venus died (!VC_OPEN(vcp)) */
-	if (codadebug)
-		myprintf(("vcclose woke op %d.%d flags %d\n",
-		   vmp->vm_opcode, vmp->vm_unique, vmp->vm_flags));
+		if (codadebug) {
+			myprintf(("vcclose woke op %d.%d flags %d\n",
+			   vmp->vm_opcode, vmp->vm_unique, vmp->vm_flags));
+		}
 
 		error = ENODEV;
 	}



CVS commit: src/sys/coda

2023-08-02 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Thu Aug  3 03:10:23 UTC 2023

Modified Files:
src/sys/coda: coda_psdev.c

Log Message:
coda_call(): Appease GCC 12.3.0 -Wmisleading-indentation
No binary changes.


To generate a diff of this commit:
cvs rdiff -u -r1.62 -r1.63 src/sys/coda/coda_psdev.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/coda

2021-12-05 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Sun Dec  5 08:10:39 UTC 2021

Modified Files:
src/sys/coda: coda_vnops.c

Log Message:
s/sybolic/symbolic/ in comment.


To generate a diff of this commit:
cvs rdiff -u -r1.116 -r1.117 src/sys/coda/coda_vnops.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/coda/coda_vnops.c
diff -u src/sys/coda/coda_vnops.c:1.116 src/sys/coda/coda_vnops.c:1.117
--- src/sys/coda/coda_vnops.c:1.116	Wed Oct 20 03:08:16 2021
+++ src/sys/coda/coda_vnops.c	Sun Dec  5 08:10:39 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: coda_vnops.c,v 1.116 2021/10/20 03:08:16 thorpej Exp $	*/
+/*	$NetBSD: coda_vnops.c,v 1.117 2021/12/05 08:10:39 msaitoh Exp $	*/
 
 /*
  *
@@ -46,7 +46,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: coda_vnops.c,v 1.116 2021/10/20 03:08:16 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: coda_vnops.c,v 1.117 2021/12/05 08:10:39 msaitoh Exp $");
 
 #include 
 #include 
@@ -1465,7 +1465,7 @@ coda_symlink(void *v)
 /*
  * Here's the strategy for the moment: perform the symlink, then
  * do a lookup to grab the resulting vnode.  I know this requires
- * two communications with Venus for a new sybolic link, but
+ * two communications with Venus for a new symbolic link, but
  * that's the way the ball bounces.  I don't yet want to change
  * the way the Mach symlink works.  When Mach support is
  * deprecated, we should change symlink so that the common case



CVS commit: src/sys/coda

2021-12-05 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Sun Dec  5 08:10:39 UTC 2021

Modified Files:
src/sys/coda: coda_vnops.c

Log Message:
s/sybolic/symbolic/ in comment.


To generate a diff of this commit:
cvs rdiff -u -r1.116 -r1.117 src/sys/coda/coda_vnops.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



Re: CVS commit: src/sys/coda

2013-11-23 Thread Christos Zoulas
In article <20131123234556.1b4ac14a...@mail.netbsd.org>,
Mindaugas Rasiukevicius   wrote:
>chris...@zoulas.com (Christos Zoulas) wrote:
>> On Nov 23, 11:24pm, rm...@netbsd.org (Mindaugas Rasiukevicius) wrote:
>> -- Subject: Re: CVS commit: src/sys/coda
>> 
>> | mp = mp == TAILQ_END(&mountlist) ? NULL : mp;
>> | 
>> | Over:
>> | 
>> | return mp;
>> | 
>> | Everybody understood NULL, so why obfuscate the code?
>> 
>> The point (as I understand it) is so that if you want to change to another
>> ADT where end != NULL (are there any now, that we have banned CIRCLEQ?)
>> using the END macro lets you s/FOOQ/BARQ/ and have it mostly work.
>
>Since 1990s (or even earlier) none of the lists in queue(3) had _END(),
>apart from the circle queue (for a very obvious reason it makes sense).
>Now that CIRCLEQ is banned - you added _END() for LIST and TAILQ.  I do
>not follow the logic. :)

*I* did appear do be adding it from the commit message, but in reality
I was syncing with OpenBSD/FreeBSD.

>I would remove _END() macros to keep the way it always was.

Perhaps that's a good idea now that it is always NULL.

>If the goal
>is to improve the interface, then now is a good time to design a new API,
>but we already have a long thread on tech-userlevel for this..

Yes, so let's leave it the way it is now, and we'll make all the changes
in one go.

christos



Re: CVS commit: src/sys/coda

2013-11-23 Thread Mindaugas Rasiukevicius
chris...@zoulas.com (Christos Zoulas) wrote:
> On Nov 23, 11:24pm, rm...@netbsd.org (Mindaugas Rasiukevicius) wrote:
> -- Subject: Re: CVS commit: src/sys/coda
> 
> | mp = mp == TAILQ_END(&mountlist) ? NULL : mp;
> | 
> | Over:
> | 
> | return mp;
> | 
> | Everybody understood NULL, so why obfuscate the code?
> 
> The point (as I understand it) is so that if you want to change to another
> ADT where end != NULL (are there any now, that we have banned CIRCLEQ?)
> using the END macro lets you s/FOOQ/BARQ/ and have it mostly work.

Since 1990s (or even earlier) none of the lists in queue(3) had _END(),
apart from the circle queue (for a very obvious reason it makes sense).
Now that CIRCLEQ is banned - you added _END() for LIST and TAILQ.  I do
not follow the logic. :)

I would remove _END() macros to keep the way it always was.  If the goal
is to improve the interface, then now is a good time to design a new API,
but we already have a long thread on tech-userlevel for this..

-- 
Mindaugas


Re: CVS commit: src/sys/coda

2013-11-23 Thread Christos Zoulas
On Nov 23, 11:24pm, rm...@netbsd.org (Mindaugas Rasiukevicius) wrote:
-- Subject: Re: CVS commit: src/sys/coda

| mp = mp == TAILQ_END(&mountlist) ? NULL : mp;
| 
| Over:
| 
| return mp;
| 
| Everybody understood NULL, so why obfuscate the code?

The point (as I understand it) is so that if you want to change to another
ADT where end != NULL (are there any now, that we have banned CIRCLEQ?)
using the END macro lets you s/FOOQ/BARQ/ and have it mostly work.

christos


Re: CVS commit: src/sys/coda

2013-11-23 Thread Mindaugas Rasiukevicius
chris...@zoulas.com (Christos Zoulas) wrote:
> On Nov 23,  6:14pm, rm...@netbsd.org (Mindaugas Rasiukevicius) wrote:
> -- Subject: Re: CVS commit: src/sys/coda
> 
> | Although this is correct, TAILQ_END(&mountlist) *suggests* access of
> | mountlist.  If it would be true, it would be unlocked and buggy access.
> | Why not just "return mp;" ?
> | 
> | It seems to me that TAILQ_END() makes the code more missleading without
> | doing any good.  What was the rationale behind adding and using it?
> 
> I think it was provided so that the macros look the same across different
> ADT's. Don't shoot the messenger, I did not add it. But I will fix the
> locking non-issue...

Revision 1.54 of queue.h shows you.  Thanks for improving it, but I still
do not see the benefit of:

mp = mp == TAILQ_END(&mountlist) ? NULL : mp;

Over:

return mp;

Everybody understood NULL, so why obfuscate the code?

-- 
Mindaugas


Re: CVS commit: src/sys/coda

2013-11-23 Thread Christos Zoulas
On Nov 23,  6:14pm, rm...@netbsd.org (Mindaugas Rasiukevicius) wrote:
-- Subject: Re: CVS commit: src/sys/coda

| Although this is correct, TAILQ_END(&mountlist) *suggests* access of
| mountlist.  If it would be true, it would be unlocked and buggy access.
| Why not just "return mp;" ?
| 
| It seems to me that TAILQ_END() makes the code more missleading without
| doing any good.  What was the rationale behind adding and using it?

I think it was provided so that the macros look the same across different
ADT's. Don't shoot the messenger, I did not add it. But I will fix the
locking non-issue...

christos


Re: CVS commit: src/sys/coda

2013-11-23 Thread Mindaugas Rasiukevicius
"Christos Zoulas"  wrote:
> Module Name:  src
> Committed By: christos
> Date: Sat Nov 23 17:57:23 UTC 2013
> 
> Modified Files:
>   src/sys/coda: coda_vfsops.c
> 
> Log Message:
> replace open-coded scan with macro; fix locking
> 

-/* mount structure wasn't found */
-return(NULL);
+mutex_exit(&mountlist_lock);
+return mp == TAILQ_END(&mountlist) ? NULL : mp;

Although this is correct, TAILQ_END(&mountlist) *suggests* access of
mountlist.  If it would be true, it would be unlocked and buggy access.
Why not just "return mp;" ?

It seems to me that TAILQ_END() makes the code more missleading without
doing any good.  What was the rationale behind adding and using it?

-- 
Mindaugas