remove msdosfs findwin95()
authorjsg <jsg@openbsd.org>
Mon, 15 Aug 2022 01:47:09 +0000 (01:47 +0000)
committerjsg <jsg@openbsd.org>
Mon, 15 Aug 2022 01:47:09 +0000 (01:47 +0000)
unused since msdosfs_vfsops.c 1.95
ok miod@ millert@

sys/msdosfs/denode.h
sys/msdosfs/msdosfs_lookup.c

index bf36e6f..308f682 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: denode.h,v 1.35 2022/06/26 05:20:42 visa Exp $        */
+/*     $OpenBSD: denode.h,v 1.36 2022/08/15 01:47:09 jsg Exp $ */
 /*     $NetBSD: denode.h,v 1.24 1997/10/17 11:23:39 ws Exp $   */
 
 /*-
@@ -306,5 +306,4 @@ int readep(struct msdosfsmount *, uint32_t, uint32_t, struct buf **, struct dire
 void reinsert(struct denode *);
 int removede(struct denode *, struct denode *);
 int uniqdosname(struct denode *, struct componentname *, u_char *);
-int findwin95(struct denode *);
 #endif /* _KERNEL */
index 5453013..f880e29 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: msdosfs_lookup.c,v 1.33 2022/01/11 03:13:59 jsg Exp $ */
+/*     $OpenBSD: msdosfs_lookup.c,v 1.34 2022/08/15 01:47:09 jsg Exp $ */
 /*     $NetBSD: msdosfs_lookup.c,v 1.34 1997/10/18 22:12:27 ws Exp $   */
 
 /*-
@@ -1048,53 +1048,3 @@ uniqdosname(struct denode *dep, struct componentname *cnp, u_char *cp)
 
        return (EEXIST);
 }
-
-/*
- * Find any Win'95 long filename entry in directory dep
- */
-int
-findwin95(struct denode *dep)
-{
-       struct msdosfsmount *pmp = dep->de_pmp;
-       struct direntry *dentp;
-       int blsize;
-       uint32_t cn;
-       daddr_t bn;
-       struct buf *bp;
-
-       /*
-        * Read through the directory looking for Win'95 entries
-        * Note: Error currently handled just as EOF                    XXX
-        */
-       for (cn = 0;; cn++) {
-               if (pcbmap(dep, cn, &bn, 0, &blsize))
-                       return 0;
-               if (bread(pmp->pm_devvp, bn, blsize, &bp)) {
-                       brelse(bp);
-                       return 0;
-               }
-               for (dentp = (struct direntry *)bp->b_data;
-                    (char *)dentp < bp->b_data + blsize;
-                    dentp++) {
-                       if (dentp->deName[0] == SLOT_EMPTY) {
-                               /*
-                                * Last used entry and not found
-                                */
-                               brelse(bp);
-                               return 0;
-                       }
-                       if (dentp->deName[0] == SLOT_DELETED) {
-                               /*
-                                * Ignore deleted files
-                                * Note: might be an indication of Win'95 anyway        XXX
-                                */
-                               continue;
-                       }
-                       if (dentp->deAttributes == ATTR_WIN95) {
-                               brelse(bp);
-                               return 1;
-                       }
-               }
-               brelse(bp);
-       }
-}