码迷,mamicode.com
首页 > 其他好文 > 详细

N service创建

时间:2016-10-25 19:48:44      阅读:186      评论:0      收藏:0      [点我收藏+]

标签:android service

M之前版本在一个进程中创建media相关所有服务

av/media/mediaserver/main_mediaserver.cpp        

        sp<IServiceManager> sm = defaultServiceManager();
        ALOGI("ServiceManager: %p", sm.get());
        AudioFlinger::instantiate();
        MediaPlayerService::instantiate();
        ResourceManagerService::instantiate();
        CameraService::instantiate();
        AudioPolicyService::instantiate();
        SoundTriggerHwService::instantiate();
        RadioService::instantiate();
        registerExtensions();
        ProcessState::self()->startThreadPool();
        IPCThreadState::self()->joinThreadPool();

N版本将各个服务转移到不同进程中进行创建

media/audioserver/main_audioserver.cpp:        AudioPolicyService::instantiate();
camera/cameraserver/main_cameraserver.cpp:    CameraService::instantiate();
media/mediaserver/main_mediaserver.cpp:    MediaPlayerService::instantiate();


N service创建

标签:android service

原文地址:http://lindt.blog.51cto.com/9699125/1865512

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!