Hi Dennis,

Thanks for your instructions.
In fact, I have included the ashmem module in the kernel
configuration. I use the remote gdb to debug the kernel and find that
the ashmem_init is called.  I find that ashmem is registered as a misc
device using misc_deregister(&ashmem_misc);

With your help, I find the code patch in init is:
device_init->
coldboot->
do_coldboot->
handle_device_fd->handle_device_event->handle_device_event ->make_device.

Then I use remote gdb to debug the init. However, the make_device
function are not called at all.

Any more suggestions?

yajin

http://vm-kernel.org



On Tue, Oct 13, 2009 at 10:36 AM, Dennis.Yxun <[email protected]> wrote:
> HI yajin:
>    Glad to see that you are play with MIPS ;-)
>    I spend a few times looking into the code, and find it will creat all the
> device nodes during
> execution of init.
>    system/core/init/ -> file devices.c -> handle_device_event ->make_device
>
> Dennis
>
> On Mon, Oct 12, 2009 at 6:07 PM, yajin <[email protected]> wrote:
>>
>> Hi all,
>>
>> Now I am working on adding goldfish target support to MIPS target so
>> that the MIPS users can have a SDK to play with.
>>
>> The kernel part works well until entering the userland. The init hangs
>> when calling ashmem_create_region. In function ashmem_create_region,
>> it will open /dev/ashmem and it return -1 and the errno is 19 which
>> means no such devices. I do not find where this device(/dev/ashmem) is
>> created? Can anyone tell me the code path of creating device /dev/
>> ashmem? Thanks very much.
>>
>> int ashmem_create_region(const char *name, size_t size)
>> {
>>        ......
>>        fd = open(ASHMEM_DEVICE, O_RDWR);
>>        if (fd < 0)
>>                return fd;
>>
>>        ......
>> }
>>
>>
>> yajin
>> http://vm-kernel.org/blog
>>
>>
>>
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
unsubscribe: [email protected]
website: http://groups.google.com/group/android-porting
-~----------~----~----~----~------~----~------~--~---

Reply via email to