Skip to contentSkip to conversation

cifs: fix build on !CONFIG_KEYS

PATCH In review Ingo Molnar 4 participants 6 messages Oct 12, 2008 VFS

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 cifs: fix build on !CONFIG_KEYS

hi,

find a quick build fix for CIFS below - you might have it already. Please double-check.

Ingo

----------->

Quoted 1 line

From 9d65371d47bc0285a557f279d402764f73551d3c Mon Sep 17 00:00:00 2001

From: Ingo Molnar <[email protected]>
Date: Sun, 12 Oct 2008 13:01:52 +0200
Subject: [PATCH] cifs: fix build on !CONFIG_KEYS
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit

CIFS has keys infrastructure dependencies:

fs/cifs/sess.c: In function ‘CIFS_SessSetup’:
fs/cifs/sess.c:628: error: implicit declaration of function ‘key_revoke’

So express that dependency in the Kconfig.

---
 fs/Kconfig |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
fs/Kconfig +1 -0
index 40183d9..c0eade5 100644
@@ -1876,6 +1876,7 @@ config SMB_NLS_REMOTE
 config CIFS
 	tristate "CIFS support (advanced network filesystem, SMBFS successor)"
 	depends on INET
+	depends on KEYS
 	select NLS
 	help
 	  This is the client VFS module for the Common Internet File System
#1 lore raw
Quoted 5 lines · Ingo Molnar

hi,

find a quick build fix for CIFS below - you might have it already. Please double-check.

Heh, I've just sent another fix for the same issue. :-)

Thanks,
Rafael

Quoted 33 lines

----------->
From 9d65371d47bc0285a557f279d402764f73551d3c Mon Sep 17 00:00:00 2001
From: Ingo Molnar <[email protected]>
Date: Sun, 12 Oct 2008 13:01:52 +0200
Subject: [PATCH] cifs: fix build on !CONFIG_KEYS
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit

CIFS has keys infrastructure dependencies:

fs/cifs/sess.c: In function ‘CIFS_SessSetup’:
fs/cifs/sess.c:628: error: implicit declaration of function ‘key_revoke’

So express that dependency in the Kconfig.

---
 fs/Kconfig |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
fs/Kconfig +1 -0
index 40183d9..c0eade5 100644
@@ -1876,6 +1876,7 @@ config SMB_NLS_REMOTE
 config CIFS
 	tristate "CIFS support (advanced network filesystem, SMBFS successor)"
 	depends on INET
+	depends on KEYS
 	select NLS
 	help
 	  This is the client VFS module for the Common Internet File System
#2 lore raw

Dang it. I got to this one late. I literally -just- fixed it locally.

- Steven

Quoted 52 lines · Rafael J. Wysocki
Quoted 5 lines · Ingo Molnar

hi,

find a quick build fix for CIFS below - you might have it already. Please double-check.

Heh, I've just sent another fix for the same issue. :-)

Thanks,
Rafael

Quoted 26 lines

----------->
From 9d65371d47bc0285a557f279d402764f73551d3c Mon Sep 17 00:00:00 2001
From: Ingo Molnar <[email protected]>
Date: Sun, 12 Oct 2008 13:01:52 +0200
Subject: [PATCH] cifs: fix build on !CONFIG_KEYS
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit

CIFS has keys infrastructure dependencies:

fs/cifs/sess.c: In function 'CIFS_SessSetup':
fs/cifs/sess.c:628: error: implicit declaration of function 'key_revoke'

So express that dependency in the Kconfig.

---
 fs/Kconfig |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
fs/Kconfig +0 -0
index 40183d9..c0eade5 100644

fs/Kconfig config SMB_NLS_REMOTE · line 1882

Quoted 7 lines
fs/Kconfig +1 -0
@@ -1876,6 +1876,7 @@ config SMB_NLS_REMOTE
 config CIFS
      tristate "CIFS support (advanced network filesystem, SMBFS successor)"
      depends on INET
+     depends on KEYS
      select NLS
      help
        This is the client VFS module for the Common Internet File System

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#3 lore raw

Hmm, which fix is correct though? Depending on KEYS in Kconfig, or adding a nop for it?

- Steven

Quoted 58 lines · Steven Noonan

Dang it. I got to this one late. I literally -just- fixed it locally.

- Steven

Quoted 52 lines · Rafael J. Wysocki
Quoted 5 lines · Ingo Molnar

hi,

find a quick build fix for CIFS below - you might have it already. Please double-check.

Heh, I've just sent another fix for the same issue. :-)

Thanks,
Rafael

Quoted 26 lines

----------->
From 9d65371d47bc0285a557f279d402764f73551d3c Mon Sep 17 00:00:00 2001
From: Ingo Molnar <[email protected]>
Date: Sun, 12 Oct 2008 13:01:52 +0200
Subject: [PATCH] cifs: fix build on !CONFIG_KEYS
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit

CIFS has keys infrastructure dependencies:

fs/cifs/sess.c: In function 'CIFS_SessSetup':
fs/cifs/sess.c:628: error: implicit declaration of function 'key_revoke'

So express that dependency in the Kconfig.

---
 fs/Kconfig |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
fs/Kconfig +0 -0
index 40183d9..c0eade5 100644

fs/Kconfig config SMB_NLS_REMOTE · line 1882

Quoted 7 lines
fs/Kconfig +1 -0
@@ -1876,6 +1876,7 @@ config SMB_NLS_REMOTE
 config CIFS
      tristate "CIFS support (advanced network filesystem, SMBFS successor)"
      depends on INET
+     depends on KEYS
      select NLS
      help
        This is the client VFS module for the Common Internet File System

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#4 lore raw
Quoted 2 lines · Steven Noonan

Hmm, which fix is correct though? Depending on KEYS in Kconfig, or adding a nop for it?

Well, according to git-blame the key_revoke() has been added to fs/cifs/sess.c only recently while key_put() was there before. For this reason I think it's correct to handle key_revoke() in analogy with key_put(), ie. add an empty definition for it if CONFIG_KEYS is unset.

Thanks,
Rafael

Quoted 61 lines · Steven Noonan
Quoted 58 lines

Dang it. I got to this one late. I literally -just- fixed it locally.

- Steven

Quoted 52 lines · Rafael J. Wysocki
Quoted 5 lines · Ingo Molnar

hi,

find a quick build fix for CIFS below - you might have it already. Please double-check.

Heh, I've just sent another fix for the same issue. :-)

Thanks,
Rafael

Quoted 26 lines

----------->
From 9d65371d47bc0285a557f279d402764f73551d3c Mon Sep 17 00:00:00 2001
From: Ingo Molnar <[email protected]>
Date: Sun, 12 Oct 2008 13:01:52 +0200
Subject: [PATCH] cifs: fix build on !CONFIG_KEYS
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit

CIFS has keys infrastructure dependencies:

fs/cifs/sess.c: In function 'CIFS_SessSetup':
fs/cifs/sess.c:628: error: implicit declaration of function 'key_revoke'

So express that dependency in the Kconfig.

---
 fs/Kconfig |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
fs/Kconfig +0 -0
index 40183d9..c0eade5 100644

fs/Kconfig config SMB_NLS_REMOTE · line 1882

Quoted 7 lines
fs/Kconfig +1 -0
@@ -1876,6 +1876,7 @@ config SMB_NLS_REMOTE
 config CIFS
      tristate "CIFS support (advanced network filesystem, SMBFS successor)"
      depends on INET
+     depends on KEYS
      select NLS
      help
        This is the client VFS module for the Common Internet File System

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#5 lore raw
Quoted 4 lines · On Sun, 12 Oct 2008 13:30:48 +0200 "Rafael J. Wysocki" <[email protected]> wrote:
Quoted 2 lines · Steven Noonan

Hmm, which fix is correct though? Depending on KEYS in Kconfig, or adding a nop for it?

Quoted 8 lines

Well, according to git-blame the key_revoke() has been added to fs/cifs/sess.c only recently while key_put() was there before. For this reason I think it's correct to handle key_revoke() in analogy with key_put(), ie. add an empty definition for it if CONFIG_KEYS is unset.

Thanks,
Rafael

Agreed. It should be possible to build CIFS w/o KEYS support. Adding an empty key_revoke looks like the right thing to do. Looks like Adrian Bunk sent a patch for this a few hours ago:

Subject: [2.6 patch] add key_revoke() dummy for KEYS=n

Signature · 1 line
Jeff Layton <[email protected]>