linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Adrian Bunk <bunk@stusta.de>
To: Andrew Morton <akpm@osdl.org>
Cc: vandrove@vc.cvut.cz, linware@sh.cvut.cz, linux-kernel@vger.kernel.org
Subject: [2.6 patch] fs/ncpfs/: remove unused #ifdef USE_OLD_SLOW_DIRECTORY_LISTING code
Date: Sun, 1 May 2005 17:42:14 +0200	[thread overview]
Message-ID: <20050501154214.GL3592@stusta.de> (raw)

This patch removes some unused #ifdef USE_OLD_SLOW_DIRECTORY_LISTING 
code.

Signed-off-by: Adrian Bunk <bunk@stusta.de>

---

This patch was alread sent on:
- 23 Apr 2005

 fs/ncpfs/dir.c           |   13 ------------
 fs/ncpfs/ncplib_kernel.c |   40 ---------------------------------------
 fs/ncpfs/ncplib_kernel.h |    3 --
 3 files changed, 56 deletions(-)

--- linux-2.6.12-rc2-mm3-full/fs/ncpfs/dir.c.old	2005-04-20 23:53:44.000000000 +0200
+++ linux-2.6.12-rc2-mm3-full/fs/ncpfs/dir.c	2005-04-20 23:53:56.000000000 +0200
@@ -705,18 +705,6 @@
 		DPRINTK("ncp_do_readdir: init failed, err=%d\n", err);
 		return;
 	}
-#ifdef USE_OLD_SLOW_DIRECTORY_LISTING
-	for (;;) {
-		err = ncp_search_for_file_or_subdir(server, &seq, &entry.i);
-		if (err) {
-			DPRINTK("ncp_do_readdir: search failed, err=%d\n", err);
-			break;
-		}
-		entry.volume = entry.i.volNumber;
-		if (!ncp_fill_cache(filp, dirent, filldir, ctl, &entry))
-			break;
-	}
-#else
 	/* We MUST NOT use server->buffer_size handshaked with server if we are
 	   using UDP, as for UDP server uses max. buffer size determined by
 	   MTU, and for TCP server uses hardwired value 65KB (== 66560 bytes). 
@@ -754,7 +742,6 @@
 		}
 	} while (more);
 	vfree(buf);
-#endif
 	return;
 }
 
--- linux-2.6.12-rc2-mm3-full/fs/ncpfs/ncplib_kernel.h.old	2005-04-20 23:54:04.000000000 +0200
+++ linux-2.6.12-rc2-mm3-full/fs/ncpfs/ncplib_kernel.h	2005-04-20 23:54:11.000000000 +0200
@@ -87,9 +87,6 @@
 
 int ncp_initialize_search(struct ncp_server *, struct inode *,
 		      struct nw_search_sequence *target);
-int ncp_search_for_file_or_subdir(struct ncp_server *server,
-			      struct nw_search_sequence *seq,
-			      struct nw_info_struct *target);
 int ncp_search_for_fileset(struct ncp_server *server,
 			   struct nw_search_sequence *seq,
 			   int* more, int* cnt,
--- linux-2.6.12-rc2-mm3-full/fs/ncpfs/ncplib_kernel.c.old	2005-04-20 23:54:19.000000000 +0200
+++ linux-2.6.12-rc2-mm3-full/fs/ncpfs/ncplib_kernel.c	2005-04-20 23:54:26.000000000 +0200
@@ -845,46 +845,6 @@
 	return result;
 }
 
-/* Search for everything */
-int ncp_search_for_file_or_subdir(struct ncp_server *server,
-				  struct nw_search_sequence *seq,
-				  struct nw_info_struct *target)
-{
-	int result;
-
-	ncp_init_request(server);
-	ncp_add_byte(server, 3);	/* subfunction */
-	ncp_add_byte(server, server->name_space[seq->volNumber]);
-	ncp_add_byte(server, 0);	/* data stream (???) */
-	ncp_add_word(server, cpu_to_le16(0x8006));	/* Search attribs */
-	ncp_add_dword(server, RIM_ALL);		/* return info mask */
-	ncp_add_mem(server, seq, 9);
-#ifdef CONFIG_NCPFS_NFS_NS
-	if (server->name_space[seq->volNumber] == NW_NS_NFS) {
-		ncp_add_byte(server, 0);	/* 0 byte pattern */
-	} else 
-#endif
-	{
-		ncp_add_byte(server, 2);	/* 2 byte pattern */
-		ncp_add_byte(server, 0xff);	/* following is a wildcard */
-		ncp_add_byte(server, '*');
-	}
-	
-	if ((result = ncp_request(server, 87)) != 0)
-		goto out;
-	memcpy(seq, ncp_reply_data(server, 0), sizeof(*seq));
-	ncp_extract_file_info(ncp_reply_data(server, 10), target);
-
-	ncp_unlock_server(server);
-	
-	result = ncp_obtain_nfs_info(server, target);
-	return result;
-
-out:
-	ncp_unlock_server(server);
-	return result;
-}
-
 int ncp_search_for_fileset(struct ncp_server *server,
 			   struct nw_search_sequence *seq,
 			   int* more,


             reply	other threads:[~2005-05-01 15:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-01 15:42 Adrian Bunk [this message]
  -- strict thread matches above, loose matches on Subject: below --
2005-04-23  0:02 [2.6 patch] fs/ncpfs/: remove unused #ifdef USE_OLD_SLOW_DIRECTORY_LISTING code Adrian Bunk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050501154214.GL3592@stusta.de \
    --to=bunk@stusta.de \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linware@sh.cvut.cz \
    --cc=vandrove@vc.cvut.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).