From mboxrd@z Thu Jan 1 00:00:00 1970 From: erik quanstrom To: Michael Baldwin References: <20051203031313.DF49018AE1F@dexter-peak.quanstro.net> <20051203145430.4E910B02F3@conchobor.berzerked.org> <6114CFD8-C785-425A-AEDB-5397D83E069C@cibernet.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 In-Reply-To: <6114CFD8-C785-425A-AEDB-5397D83E069C@cibernet.com> Subject: Re: [9fans] 9pserve question Message-Id: <20051203170023.C0E7318AE27@dexter-peak.quanstro.net> Date: Sat, 3 Dec 2005 11:00:23 -0600 Cc: Topicbox-Message-UUID: b6e5553a-ead0-11e9-9d60-3106f5b1d025 good question. i believe that this is the problem -- and it's not specific to the linux 9p "filesystem. fs/namei.c has this function which is called when trying to open a file: i didn't follow up on what put_write_access() does but i'm betting that that generates the wstat. 1324 int may_open(struct nameidata *nd, int acc_mode, int flag) 1325 { [...] 1379 if (flag & O_TRUNC) { 1380 error = get_write_access(inode); 1381 if (error) 1382 return error; 1383 1384 /* 1385 * Refuse to truncate files with mandatory locks held on them. 1386 */ 1387 error = locks_verify_locked(inode); 1388 if (!error) { 1389 DQUOT_INIT(inode); 1390 1391 error = do_truncate(dentry, 0); 1392 } 1393 put_write_access(inode); 1394 if (error) 1395 return error; [...] - erik Michael Baldwin writes | | why is it doing Tstat and Twstat at all? i would have thought it | would be Twalk, Topen, Twrite. |