need to initialize a member of a struct (error doing it)

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

 



Hi there!

I have a problem with a shared strcture that is used either from the user and kernel side.

I need to initialize it from the kernel side, so, when I declare the struct and before doing EXPORT_SYMBOL I try to initialize a member of the structure and when I compile I'm getting an error that says "decodification error before "." "

I don't know if I'm not asigning correctly the value or if there's another problem, do you see anything wrong??

struct defintion: in a header file <bitmap.h>

struct bitmap_struct{
 struct task_struct *bitmaptask;

 unsigned long initial;
 unsigned long final;
 unsigned long length;
 int *init_kernel;
};

declaration in kernel side and asignation of a value to pid ( what's going wrong)
...done include <linux/bitmap.h>


struct bitmap_struct bitmapped;
bitmapped.bitmaptask->pid= -1;  -----> the compiling error is appearing here
EXPORT_SYMBOL(bitmapped);

Thanks in advance,

Cristina.

_________________________________________________________________
Horóscopo, tarot, numerología... Escucha lo que te dicen los astros. http://astrocentro.msn.es/



-- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/


[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