Hi J. R.

I know you have almost no time to look into this but the latest code of aufs 
2.1 don't work with 2.6.36 yet. Current error is now:

branch.c:859:2: error: request for member 'next' in something not a structure 
or union

A full error log and the code snippet where the problem is is attached.
I managed to fix module problems I had with this new kernel to fix so only 
aufs2 
is still on my list:

http://chakra-project.org/bbs/viewtopic.php?pid=22281#p22281

I'm glad for any help on this problem. Steven Barrett might have also time to 
look into it ...

greez

Phil
p...@[chroot]:~/buildroot/core-testing/aufs2.1$ ../makepkg
==> Making package: aufs2.1 2.6.36_20101022-1 (Sat Oct 23 09:05:42 UTC 2010)
==> Checking Runtime Dependencies...
==> Checking Buildtime Dependencies...
==> Retrieving Sources...
  -> Found aufs2.1-2.6.36_20101022.tar.gz
==> Validating source files with md5sums...
    aufs2.1-2.6.36_20101022.tar.gz ... Passed
==> Extracting Sources...
  -> Extracting aufs2.1-2.6.36_20101022.tar.gz with bsdtar
==> Removing existing pkg/ directory...
==> Entering fakeroot environment...
==> Starting build()...
==> start config
-I/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/include 
-DCONFIG_AUFS_MODULE -UCONFIG_AUFS -DCONFIG_AUFS_BRANCH_MAX_127 
-DCONFIG_AUFS_HNOTIFY -DCONFIG_AUFS_HFSNOTIFY -DCONFIG_AUFS_EXPORT 
-DCONFIG_AUFS_SHWH -DCONFIG_AUFS_BR_RAMFS -DCONFIG_AUFS_BDEV_LOOP
make -C /usr/src/linux-2.6.36-CHAKRA 
M=/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs 
EXTRA_CFLAGS="-I/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/include
 -DCONFIG_AUFS_MODULE -UCONFIG_AUFS -DCONFIG_AUFS_BRANCH_MAX_127 
-DCONFIG_AUFS_HNOTIFY -DCONFIG_AUFS_HFSNOTIFY -DCONFIG_AUFS_EXPORT 
-DCONFIG_AUFS_SHWH -DCONFIG_AUFS_BR_RAMFS -DCONFIG_AUFS_BDEV_LOOP" modules
make[1]: Entering directory `/usr/src/linux-2.6.36-CHAKRA'
  CC [M]  
/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs/module.o
  CC [M]  
/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs/sbinfo.o
  CC [M]  
/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs/super.o
  CC [M]  
/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs/branch.o
/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs/branch.c:
 In function 'au_br_mod_files_ro':
/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs/branch.c:859:2:
 error: request for member 'next' in something not a structure or union
/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs/branch.c:859:2:
 warning: comparison of distinct pointer types lacks a cast
make[2]: *** 
[/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs/branch.o]
 Error 1
make[1]: *** 
[_module_/home/phil/buildroot/core-testing/aufs2.1/src/aufs2.1-2.6.36_20101022/fs/aufs]
 Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.36-CHAKRA'
make: *** [fs/aufs/aufs.ko] Error 2
    Aborting...


Code snippet:

static int au_br_mod_files_ro(struct super_block *sb, aufs_bindex_t bindex)
{
        int err;
        unsigned long n, ul, bytes, files;
        aufs_bindex_t bstart;
        struct file *file, *hf, **a;
        const int step_bytes = 1024, /* memory allocation unit */
                step_files = step_bytes / sizeof(*a);

        err = -ENOMEM;
        n = 0;
        bytes = step_bytes;
        files = step_files;
        a = kmalloc(bytes, GFP_NOFS);
        if (unlikely(!a))
                goto out;

        /* no need file_list_lock() since sbinfo is locked? defered? */
        list_for_each_entry(file, &sb->s_files, f_u.fu_list) {
                if (special_file(file->f_dentry->d_inode->i_mode))
                        continue;

                AuDbg("%.*s\n", AuDLNPair(file->f_dentry));
                fi_read_lock(file);
                if (unlikely(au_test_mmapped(file))) {
                        err = -EBUSY;
                        FiMustNoWaiters(file);
                        fi_read_unlock(file);
                        goto out_free;
                }

                bstart = au_fbstart(file);
                if (!S_ISREG(file->f_dentry->d_inode->i_mode)
                    || !(file->f_mode & FMODE_WRITE)
                    || bstart != bindex) {
                        FiMustNoWaiters(file);
                        fi_read_unlock(file);
                        continue;
                }

                hf = au_hf_top(file);
                FiMustNoWaiters(file);
                fi_read_unlock(file);

                if (n < files)
                        a[n++] = hf;
                else {
                        void *p;

                        err = -ENOMEM;
                        bytes += step_bytes;
                        files += step_files;
                        p = krealloc(a, bytes, GFP_NOFS);
                        if (p) {
                                a = p;
                                a[n++] = hf;
                        } else
                                goto out_free;
                }
        }

        err = 0;
        if (n)
                au_warn_ima();
        for (ul = 0; ul < n; ul++) {
                /* todo: already flushed? */
                /* cf. fs/super.c:mark_files_ro() */
                hf = a[ul];
                hf->f_mode &= ~FMODE_WRITE;
                if (!file_check_writeable(hf)) {
                        file_release_write(hf);
                        mnt_drop_write(hf->f_vfsmnt);
                }
        }

out_free:
        kfree(a);
out:
        return err;
}

claimed line:

list_for_each_entry(file, &sb->s_files, f_u.fu_list) {
------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev

Reply via email to