hi Why is "can't find a register in class ‘AREG’ while reloading ‘asm’" ?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



hi all:
       The codes is:
static int match(int len,const char * name,struct dir_entry * de)
{
        register int same __asm__("ax");

        if (!de || !de->inode || len > NAME_LEN)
                return 0;
        if (len < NAME_LEN && de->name[len])
                return 0;
        __asm__ ("cld\n\t"
                "fs ; repe ; cmpsb\n\t"
                "setz %%al"
                :"=a" (same)
                :"0" (0),"S" ((long) name),"D" ((long) de->name),"c" (len)
                :"cx","di","si");
        return same;
}

When I make it, the error messages is:
namei.c:35: error: can't find a register in class ‘AREG’ while reloading ‘asm’

This is why? 
Thank you

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux