All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] fs: hpfs: remove commented out code in hpfs_set_ea
@ 2026-05-19 16:45 Thorsten Blum
  2026-05-19 16:45 ` [PATCH 2/3] fs: hpfs: calculate key length only once " Thorsten Blum
  2026-05-19 16:45 ` [PATCH 3/3] fs: hpfs: replace deprecated strcpy with memcpy " Thorsten Blum
  0 siblings, 2 replies; 3+ messages in thread
From: Thorsten Blum @ 2026-05-19 16:45 UTC (permalink / raw)
  To: Mikulas Patocka; +Cc: Thorsten Blum, linux-kernel

The code has been commented out ever since commit 1da177e4c3f4
("Linux-2.6.12-rc2") - remove it.

Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
---
 fs/hpfs/ea.c | 26 +-------------------------
 1 file changed, 1 insertion(+), 25 deletions(-)

diff --git a/fs/hpfs/ea.c b/fs/hpfs/ea.c
index 4664f9ab06ee..3f0213486c21 100644
--- a/fs/hpfs/ea.c
+++ b/fs/hpfs/ea.c
@@ -236,14 +236,8 @@ void hpfs_set_ea(struct inode *inode, struct fnode *fnode, const char *key,
 		}
 		pos += ea->namelen + ea_valuelen(ea) + 5;
 	}
-	if (!le16_to_cpu(fnode->ea_offs)) {
-		/*if (le16_to_cpu(fnode->ea_size_s)) {
-			hpfs_error(s, "fnode %08x: ea_size_s == %03x, ea_offs == 0",
-				inode->i_ino, le16_to_cpu(fnode->ea_size_s));
-			return;
-		}*/
+	if (!le16_to_cpu(fnode->ea_offs))
 		fnode->ea_offs = cpu_to_le16(0xc4);
-	}
 	if (le16_to_cpu(fnode->ea_offs) < 0xc4 || le16_to_cpu(fnode->ea_offs) + le16_to_cpu(fnode->acl_size_s) + le16_to_cpu(fnode->ea_size_s) > 0x200) {
 		hpfs_error(s, "fnode %08llx: ea_offs == %03x, ea_size_s == %03x",
 			inode->i_ino,
@@ -295,24 +289,6 @@ void hpfs_set_ea(struct inode *inode, struct fnode *fnode, const char *key,
 			if (hpfs_alloc_if_possible(s, le32_to_cpu(fnode->ea_secno) + len)) {
 				len++;
 			} else {
-				/* Aargh... don't know how to create ea anodes :-( */
-				/*struct buffer_head *bh;
-				struct anode *anode;
-				anode_secno a_s;
-				if (!(anode = hpfs_alloc_anode(s, fno, &a_s, &bh)))
-					goto bail;
-				anode->up = cpu_to_le32(fno);
-				anode->btree.fnode_parent = 1;
-				anode->btree.n_free_nodes--;
-				anode->btree.n_used_nodes++;
-				anode->btree.first_free = cpu_to_le16(le16_to_cpu(anode->btree.first_free) + 12);
-				anode->u.external[0].disk_secno = cpu_to_le32(le32_to_cpu(fnode->ea_secno));
-				anode->u.external[0].file_secno = cpu_to_le32(0);
-				anode->u.external[0].length = cpu_to_le32(len);
-				mark_buffer_dirty(bh);
-				brelse(bh);
-				fnode->flags |= FNODE_anode;
-				fnode->ea_secno = cpu_to_le32(a_s);*/
 				secno new_sec;
 				int i;
 				if (!(new_sec = hpfs_alloc_sector(s, fno, 1, 1 - ((pos + 511) >> 9))))

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

end of thread, other threads:[~2026-05-19 16:46 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-19 16:45 [PATCH 1/3] fs: hpfs: remove commented out code in hpfs_set_ea Thorsten Blum
2026-05-19 16:45 ` [PATCH 2/3] fs: hpfs: calculate key length only once " Thorsten Blum
2026-05-19 16:45 ` [PATCH 3/3] fs: hpfs: replace deprecated strcpy with memcpy " Thorsten Blum

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.