Home
last modified time | relevance | path

Searched refs:sm (Results 1 – 25 of 112) sorted by relevance

12345

/frameworks/native/libs/fakeservicemanager/
Dtest_sm.cpp48 auto sm = new ServiceManager(); in TEST() local
49 EXPECT_EQ(sm->addService(String16("foo"), getBinder(), false /*allowIsolated*/, in TEST()
54 auto sm = new ServiceManager(); in TEST() local
55 EXPECT_EQ(sm->addService(String16("foo"), getBinder(), false /*allowIsolated*/, in TEST()
57 EXPECT_EQ(sm->addService(String16("foo"), getBinder(), false /*allowIsolated*/, in TEST()
62 auto sm = new ServiceManager(); in TEST() local
65 EXPECT_EQ(sm->addService(String16("foo"), service, false /*allowIsolated*/, in TEST()
68 EXPECT_EQ(sm->getService(String16("foo")), service); in TEST()
72 auto sm = new ServiceManager(); in TEST() local
74 EXPECT_EQ(sm->getService(String16("foo")), nullptr); in TEST()
[all …]
/frameworks/native/cmds/servicemanager/
Dtest_sm.cpp74 sp<ServiceManager> sm = new NiceMock<MockServiceManager>(std::move(access)); in getPermissiveServiceManager() local
75 return sm; in getPermissiveServiceManager()
79 auto sm = getPermissiveServiceManager(); in TEST() local
80 EXPECT_TRUE(sm->addService("foo", getBinder(), false /*allowIsolated*/, in TEST()
85 auto sm = getPermissiveServiceManager(); in TEST() local
86 EXPECT_FALSE(sm->addService("", getBinder(), false /*allowIsolated*/, in TEST()
91 auto sm = getPermissiveServiceManager(); in TEST() local
92 EXPECT_TRUE(sm->addService(std::string(127, 'a'), getBinder(), false /*allowIsolated*/, in TEST()
97 auto sm = getPermissiveServiceManager(); in TEST() local
98 EXPECT_FALSE(sm->addService(std::string(128, 'a'), getBinder(), false /*allowIsolated*/, in TEST()
[all …]
/frameworks/base/services/tests/servicestests/src/com/android/server/
DMountServiceTests.java128 private void mountObb(StorageManager sm, final int resource, final File file, in mountObb() argument
134 sm.mountObb(file.getPath(), null, observer)); in mountObb()
140 assertTrue("OBB should be mounted", sm.isObbMounted(file.getPath())); in mountObb()
149 private ObbObserver mountObbWithoutWait(final StorageManager sm, final int resource, in mountObbWithoutWait() argument
154 assertTrue("mountObb call on " + file.getPath() + " should succeed", sm.mountObb(file in mountObbWithoutWait()
160 private void waitForObbActionCompletion(final StorageManager sm, final File file, in waitForObbActionCompletion() argument
164 assertTrue("OBB should be mounted", sm.isObbMounted(file.getPath())); in waitForObbActionCompletion()
174 private String checkMountedPath(final StorageManager sm, final File file) { in checkMountedPath() argument
175 final String mountPath = sm.getMountedObbPath(file.getPath()); in checkMountedPath()
182 private void unmountObb(final StorageManager sm, final File file, int expectedState) { in unmountObb() argument
[all …]
/frameworks/rs/
DrsApiMesh.cpp23 Mesh *sm = static_cast<Mesh *>(mv); in rsaMeshGetVertexBufferCount() local
24 *numVtx = sm->mHal.state.vertexBuffersCount; in rsaMeshGetVertexBufferCount()
28 Mesh *sm = static_cast<Mesh *>(mv); in rsaMeshGetIndexCount() local
29 *numIdx = sm->mHal.state.primitivesCount; in rsaMeshGetIndexCount()
33 Mesh *sm = static_cast<Mesh *>(mv); in rsaMeshGetVertices() local
34 rsAssert(vtxDataCount == sm->mHal.state.vertexBuffersCount); in rsaMeshGetVertices()
37 vtxData[ct] = sm->mHal.state.vertexBuffers[ct]; in rsaMeshGetVertices()
38 sm->mHal.state.vertexBuffers[ct]->incUserRef(); in rsaMeshGetVertices()
43 Mesh *sm = static_cast<Mesh *>(mv); in rsaMeshGetIndices() local
44 rsAssert(idxDataCount == sm->mHal.state.primitivesCount); in rsaMeshGetIndices()
[all …]
DrsScriptC_LibGL.cpp147 void rsrDrawPath(Context *rsc, Path *sm) { in rsrDrawPath() argument
151 void rsrDrawMesh(Context *rsc, Mesh *sm) { in rsrDrawMesh() argument
152 CHECK_OBJ(sm); in rsrDrawMesh()
156 sm->render(rsc); in rsrDrawMesh()
159 void rsrDrawMeshPrimitive(Context *rsc, Mesh *sm, uint32_t primIndex) { in rsrDrawMeshPrimitive() argument
160 CHECK_OBJ(sm); in rsrDrawMeshPrimitive()
164 sm->renderPrimitive(rsc, primIndex); in rsrDrawMeshPrimitive()
167 void rsrDrawMeshPrimitiveRange(Context *rsc, Mesh *sm, uint32_t primIndex, in rsrDrawMeshPrimitiveRange() argument
169 CHECK_OBJ(sm); in rsrDrawMeshPrimitiveRange()
173 sm->renderPrimitiveRange(rsc, primIndex, start, len); in rsrDrawMeshPrimitiveRange()
[all …]
/frameworks/base/core/tests/coretests/src/android/view/
DListContextMenu.java96 …SubMenu sm = menu.addSubMenu(0, 0, 0, "The 2nd item, a sub menu").setIcon(R.drawable.black_square_… in onCreateOptionsMenu() local
97 item = sm.getItem(); in onCreateOptionsMenu()
99 sm.add(1, 0, 0, "Subitem 1"); in onCreateOptionsMenu()
100 sm.add(1, 0, 0, "Subitem 2"); in onCreateOptionsMenu()
101 sm.add(1, 0, 0, "Subitem 3"); in onCreateOptionsMenu()
102 sm.setGroupCheckable(1, true, true); in onCreateOptionsMenu()
110 sm = menu.addSubMenu(0, 0, 0, "Item 10 SM"); in onCreateOptionsMenu()
111 sm.add(0, 0, 0, "Subitem 1"); in onCreateOptionsMenu()
112 sm.add(0, 0, 0, "Subitem 2"); in onCreateOptionsMenu()
113 sm.add(0, 0, 0, "Subitem 3"); in onCreateOptionsMenu()
[all …]
/frameworks/native/libs/binder/include/binder/
DIServiceManager.h109 void setDefaultServiceManager(const sp<IServiceManager>& sm);
113 const sp<IServiceManager> sm = defaultServiceManager(); in waitForService() local
114 return interface_cast<INTERFACE>(sm->waitForService(name)); in waitForService()
119 const sp<IServiceManager> sm = defaultServiceManager(); in waitForDeclaredService() local
120 if (!sm->isDeclared(name)) return nullptr; in waitForDeclaredService()
121 return interface_cast<INTERFACE>(sm->waitForService(name)); in waitForDeclaredService()
126 const sp<IServiceManager> sm = defaultServiceManager(); in checkDeclaredService() local
127 if (!sm->isDeclared(name)) return nullptr; in checkDeclaredService()
128 return interface_cast<INTERFACE>(sm->checkService(name)); in checkDeclaredService()
148 const sp<IServiceManager> sm = defaultServiceManager(); in getService() local
[all …]
/frameworks/native/include/binder/
DIServiceManager.h109 void setDefaultServiceManager(const sp<IServiceManager>& sm);
113 const sp<IServiceManager> sm = defaultServiceManager(); in waitForService() local
114 return interface_cast<INTERFACE>(sm->waitForService(name)); in waitForService()
119 const sp<IServiceManager> sm = defaultServiceManager(); in waitForDeclaredService() local
120 if (!sm->isDeclared(name)) return nullptr; in waitForDeclaredService()
121 return interface_cast<INTERFACE>(sm->waitForService(name)); in waitForDeclaredService()
126 const sp<IServiceManager> sm = defaultServiceManager(); in checkDeclaredService() local
127 if (!sm->isDeclared(name)) return nullptr; in checkDeclaredService()
128 return interface_cast<INTERFACE>(sm->checkService(name)); in checkDeclaredService()
148 const sp<IServiceManager> sm = defaultServiceManager(); in getService() local
[all …]
/frameworks/native/libs/binder/ndk/
Dservice_manager.cpp36 sp<IServiceManager> sm = defaultServiceManager(); in AServiceManager_addService() local
37 status_t status = sm->addService(String16(instance), binder->getBinder()); in AServiceManager_addService()
45 sp<IServiceManager> sm = defaultServiceManager(); in AServiceManager_checkService() local
46 sp<IBinder> binder = sm->checkService(String16(instance)); in AServiceManager_checkService()
57 sp<IServiceManager> sm = defaultServiceManager(); in AServiceManager_getService() local
58 sp<IBinder> binder = sm->getService(String16(instance)); in AServiceManager_getService()
/frameworks/base/core/tests/utiltests/src/com/android/internal/util/
DStateMachineTest.java64 private void dumpLogRecs(StateMachine sm) { in dumpLogRecs() argument
65 int size = sm.getLogRecSize(); in dumpLogRecs()
66 tlog("size=" + size + " count=" + sm.getLogRecCount()); in dumpLogRecs()
68 LogRec lr = sm.getLogRec(i); in dumpLogRecs()
1671 StateMachineUnhandledMessage sm = new StateMachineUnhandledMessage("smUnhandledMessage"); in testStateMachineUnhandledMessage() local
1672 sm.start(); in testStateMachineUnhandledMessage()
1673 if (sm.isDbg()) tlog("testStateMachineUnhandledMessage E"); in testStateMachineUnhandledMessage()
1675 synchronized (sm) { in testStateMachineUnhandledMessage()
1678 sm.sendMessage(i); in testStateMachineUnhandledMessage()
1683 sm.wait(); in testStateMachineUnhandledMessage()
[all …]
/frameworks/base/core/java/com/android/internal/util/
DAsyncChannel.java806 SyncMessenger sm; in obtain() local
809 sm = new SyncMessenger(); in obtain()
810 sm.mHandlerThread = new HandlerThread("SyncHandler-" + sCount++); in obtain()
811 sm.mHandlerThread.start(); in obtain()
812 sm.mHandler = sm.new SyncHandler(sm.mHandlerThread.getLooper()); in obtain()
813 sm.mMessenger = new Messenger(sm.mHandler); in obtain()
815 sm = sStack.pop(); in obtain()
818 return sm; in obtain()
837 SyncMessenger sm = SyncMessenger.obtain(); in sendMessageSynchronously() local
841 msg.replyTo = sm.mMessenger; in sendMessageSynchronously()
[all …]
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/deviceinfo/
DPrivateStorageInfo.java41 public static PrivateStorageInfo getPrivateStorageInfo(StorageVolumeProvider sm) { in getPrivateStorageInfo() argument
47 for (VolumeInfo info : sm.getVolumes()) { in getPrivateStorageInfo()
50 privateTotalBytes += sm.getTotalBytes(stats, info); in getPrivateStorageInfo()
51 privateFreeBytes += sm.getFreeBytes(stats, info); in getPrivateStorageInfo()
/frameworks/base/core/java/com/android/server/backup/
DSliceBackupHelper.java45 ISliceManager sm = ISliceManager.Stub.asInterface( in getBackupPayload() local
48 newPayload = sm.getBackupPayload(UserHandle.USER_SYSTEM); in getBackupPayload()
64 ISliceManager sm = ISliceManager.Stub.asInterface( in applyRestoredPayload() local
67 sm.applyRestore(payload, UserHandle.USER_SYSTEM); in applyRestoredPayload()
/frameworks/native/cmds/dumpsys/
Dmain.cpp32 sp<IServiceManager> sm = defaultServiceManager(); in main() local
34 if (sm == nullptr) { in main()
40 Dumpsys dumpsys(sm.get()); in main()
/frameworks/base/cmds/statsd/src/
Dstatscompanion_util.cpp29 static const sp <IServiceManager> sm(defaultServiceManager()); in getStatsCompanionService() local
31 if (sm != nullptr) { in getStatsCompanionService()
33 statsCompanion = interface_cast<IStatsCompanionService>(sm->checkService(name)); in getStatsCompanionService()
/frameworks/av/camera/cameraserver/
Dmain_cameraserver.cpp34 sp<IServiceManager> sm = defaultServiceManager(); in main() local
35 ALOGI("ServiceManager: %p", sm.get()); in main()
37 ALOGI("ServiceManager: %p done instantiate", sm.get()); in main()
/frameworks/av/media/audioserver/
Dmain_audioserver.cpp111 sp<IServiceManager> sm = defaultServiceManager(); in main() local
112 sp<IBinder> binder = sm->getService(String16("media.log")); in main()
137 sp<IServiceManager> sm = defaultServiceManager(); in main() local
138 ALOGI("ServiceManager: %p", sm.get()); in main()
/frameworks/av/media/utils/fuzzers/
DSchedulingPolicyServiceFuzz.cpp34 const sp<IServiceManager> sm(defaultServiceManager()); in getBatteryService() local
35 if (sm != nullptr) { in getBatteryService()
37 batteryStatService = checked_interface_cast<IBatteryStats>(sm->checkService(name)); in getBatteryService()
/frameworks/native/cmds/cmd/
Dcmd.cpp175 sp<IServiceManager> sm = defaultServiceManager(); in cmdMain() local
179 if (sm == nullptr) { in cmdMain()
193 Vector<String16> services = sm->listServices(); in cmdMain()
198 sp<IBinder> service = sm->checkService(services[i]); in cmdMain()
217 service = sm->waitForService(serviceName); in cmdMain()
219 service = sm->checkService(serviceName); in cmdMain()
/frameworks/native/libs/binder/
DIServiceManager.cpp95 sp<AidlServiceManager> sm = nullptr; in defaultServiceManager() local
96 while (sm == nullptr) { in defaultServiceManager()
97sm = interface_cast<AidlServiceManager>(ProcessState::self()->getContextObject(nullptr)); in defaultServiceManager()
98 if (sm == nullptr) { in defaultServiceManager()
104 gDefaultServiceManager = new ServiceManagerShim(sm); in defaultServiceManager()
110 void setDefaultServiceManager(const sp<IServiceManager>& sm) { in setDefaultServiceManager() argument
113 gDefaultServiceManager = sm; in setDefaultServiceManager()
DProcessInfoService.cpp95 const sp<IServiceManager> sm(defaultServiceManager()); in updateBinderLocked() local
96 if (sm != nullptr) { in updateBinderLocked()
98 mProcessInfoService = interface_cast<IProcessInfoService>(sm->checkService(name)); in updateBinderLocked()
/frameworks/native/services/vr/virtual_touchpad/
DVirtualTouchpadClient.cpp24 sp<IServiceManager> sm = defaultServiceManager(); in Attach() local
25 if (sm == nullptr) { in Attach()
31 sm->getService(IVirtualTouchpadService::SERVICE_NAME())); in Attach()
/frameworks/base/cmds/sm/
Dsm2 export CLASSPATH=/system/framework/sm.jar
3 exec app_process /system/bin com.android.commands.sm.Sm "$@"
DAndroid.bp5 name: "sm",
6 wrapper: "sm",
/frameworks/native/cmds/service/
Dservice.cpp99 sp<IServiceManager> sm = defaultServiceManager(); in main() local
101 if (sm == nullptr) { in main()
112 sp<IBinder> service = sm->checkService(String16(argv[optind])); in main()
122 Vector<String16> services = sm->listServices(); in main()
126 sp<IBinder> service = sm->checkService(name); in main()
136 sp<IBinder> service = sm->checkService(String16(argv[optind++])); in main()

12345