On Wed, Jul 14, 2004 at 11:07:06AM +1000, Darren Williams wrote: > Including Andrew File System on any arch other > than i386 and x86_64 will break the compilation > due to the use of 'struct_cpy()', which is only > define in the two archs above and both archs > define it differently: struct_cpy will be remove as suggest by AKPM in a recent discussion in LKML. > A quick discussion here suggests that we are not > doing a deep copy of the struct though others > may by able to enlighten us on what happens to > pointers within a struct? using only *x = *y works. > I have applied the i386 definition to ia64 and > compiles OK, though I cannot test it since I > do not have direct access to AFS. Ok, what about the following patch ? Index: fs/afs/mntpt.c =================================================================== --- fs/afs/mntpt.c (revision 1) +++ fs/afs/mntpt.c (working copy) @@ -257,7 +257,7 @@ if (IS_ERR(newmnt)) return PTR_ERR(newmnt); - struct_cpy(&newnd, nd); + newnd = *nd; newnd.dentry = dentry; err = do_add_mount(newmnt, &newnd, 0, &afs_vfsmounts); Index: fs/afs/vlocation.c =================================================================== --- fs/afs/vlocation.c (revision 1) +++ fs/afs/vlocation.c (working copy) @@ -906,7 +906,7 @@ if (!vlocation->valid || vlocation->vldb.rtime == vldb->rtime ) { - struct_cpy(&vlocation->vldb, vldb); + vlocation->vldb = *vldb; vlocation->valid = 1; _leave(" = SUCCESS [c->m]"); return CACHEFS_MATCH_SUCCESS; @@ -947,7 +947,7 @@ _enter(""); - struct_cpy(vldb,&vlocation->vldb); + *vldb = vlocation->vldb; } /* end afs_vlocation_cache_update() */ #endif -- Tab