aboutsummaryrefslogtreecommitdiff
path: root/en/devices/architecture/hidl-cpp
diff options
context:
space:
mode:
authorAndroid Partner Docs <noreply@android.com>2018-06-28 10:08:47 -0700
committerClay Murphy <claym@google.com>2018-06-28 16:32:53 -0700
commit4945711ac0fe9f19ae0d358ae00db5c03485aa53 (patch)
tree6272a7dec55b5d46dee3986d33aa97e0e2882ea0 /en/devices/architecture/hidl-cpp
parent416fec3097de0ec9ffec5a0bcd4e23cd82514eba (diff)
downloadsource.android.com-4945711ac0fe9f19ae0d358ae00db5c03485aa53.tar.gz
Docs: Changes to source.android.com
- 202498507 Devsite localized content from translation request 944914. by Android Partner Docs <noreply@android.com> - 202368991 Document seccomp crashes. by Android Partner Docs <noreply@android.com> - 202365193 Devsite localized content from translation request 941016. by Android Partner Docs <noreply@android.com> - 202334002 Devsite localized content from translation request 944913. by Android Partner Docs <noreply@android.com> - 202333988 Devsite localized content from translation request 944152. by Android Partner Docs <noreply@android.com> - 202307420 Update Implementing Vulkan page. by Android Partner Docs <noreply@android.com> - 202218233 The -j64 seems unrealistic for most users. Bumped it dow... by Gina Dimino <gdimino@google.com> - 202200614 Moving Treble content to main file (and removing treble f... by Heidi von Markham <hvm@google.com> - 202192748 Clarify HIDL threading documentation. by Android Partner Docs <noreply@android.com> - 202148581 Publish localized bulletins by Danielle Roberts <daroberts@google.com> - 202141713 Devsite localized content from translation request 937937. by Android Partner Docs <noreply@android.com> - 202141703 Devsite localized content from translation request 941621. by Android Partner Docs <noreply@android.com> - 202141693 Devsite localized content from translation request 936854. by Android Partner Docs <noreply@android.com> - 202070722 Automated g4 rollback of changelist 182578621. by Christina Nguyen <cqn@google.com> - 202039586 Noting the need for upstream patches to some projects. by Clay Murphy <claym@google.com> - 202035931 Devsite localized content from translation request 942523. by Android Partner Docs <noreply@android.com> - 201978491 Devsite localized content from translation request 940149. by Android Partner Docs <noreply@android.com> - 201749091 UpdatingHAL references/adding HIDL references by Android Partner Docs <noreply@android.com> - 201700681 Devsite localized content from translation request 940151. by Android Partner Docs <noreply@android.com> - 201700650 Devsite localized content from translation request 941012. by Android Partner Docs <noreply@android.com> - 201700579 Devsite localized content from translation request 942527. by Android Partner Docs <noreply@android.com> - 201700572 Devsite localized content from translation request 940150. by Android Partner Docs <noreply@android.com> - 201700538 Devsite localized content from translation request 932858. by Android Partner Docs <noreply@android.com> - 201700524 Devsite localized content from translation request 943117. by Android Partner Docs <noreply@android.com> - 201700504 Devsite localized content from translation request 943114. by Android Partner Docs <noreply@android.com> - 201537155 Devsite localized content from translation request 937234. by Android Partner Docs <noreply@android.com> - 201537147 Devsite localized content from translation request 941017. by Android Partner Docs <noreply@android.com> - 201532584 HAL to HIDL (change to "master" directory) by Android Partner Docs <noreply@android.com> - 201376845 Devsite localized content from translation request 910444. by Android Partner Docs <noreply@android.com> - 201371305 Devsite localized content from translation request 925769. by Android Partner Docs <noreply@android.com> - 201371295 Devsite localized content from translation request 938920. by Android Partner Docs <noreply@android.com> - 201264243 Removing version from VTS Codelab and O references. by Heidi von Markham <hvm@google.com> - 201207845 Add measurements for version 8.x on Nexus 5X, Nexus 6P, P... by Android Partner Docs <noreply@android.com> - 201195333 Devsite localized content from translation request 937940. by Android Partner Docs <noreply@android.com> - 201028550 Changed "Functional patches" table description in Pixel b... by Android Partner Docs <noreply@android.com> - 201021773 Devsite localized content from translation request 939440. by Android Partner Docs <noreply@android.com> - 201021757 Devsite localized content from translation request 939442. by Android Partner Docs <noreply@android.com> - 200732813 Devsite localized content from translation request 934614. by Android Partner Docs <noreply@android.com> - 200732804 Devsite localized content from translation request 910442. by Android Partner Docs <noreply@android.com> - 200625210 Updating warning about Valgrind deprecation by Heidi von Markham <hvm@google.com> - 200618019 Simple fix to removing misleading Git images by Heidi von Markham <hvm@google.com> - 200581373 Partner Security Updates and Resources Page has wrong OS ... by Android Partner Docs <noreply@android.com> - 200553261 Devsite localized content from translation request 936855. by Android Partner Docs <noreply@android.com> - 200553240 Devsite localized content from translation request 928419. by Android Partner Docs <noreply@android.com> - 200553234 Devsite localized content from translation request 928433. by Android Partner Docs <noreply@android.com> - 200553227 Devsite localized content from translation request 938813. by Android Partner Docs <noreply@android.com> - 200428587 Add link to CTS downloads page. by Kenneth Lau <kennethlau@google.com> - 200422176 Update CTS/CTS-Verifier downloads for CTS-Jun-2018 Releases by Android Partner Docs <noreply@android.com> - 200409107 Devsite localized content from translation request 931899. by Android Partner Docs <noreply@android.com> - 200289107 Android 7 -> Android 7.x and earlier; Android 8 -> Androi... by Android Partner Docs <noreply@android.com> - 200275031 Replace index.html with _index.yaml. by Android Partner Docs <noreply@android.com> - 200263644 Replace HAL paths with HIDL (B/78915061): In URLs, change... by Android Partner Docs <noreply@android.com> - 200159329 Hide star ratings to fix layout. by Android Partner Docs <noreply@android.com> - 200062417 Devsite localized content from translation request 915905. by Android Partner Docs <noreply@android.com> - 200062406 Devsite localized content from translation request 932855. by Android Partner Docs <noreply@android.com> - 200062403 Devsite localized content from translation request 936857. by Android Partner Docs <noreply@android.com> - 200062395 Devsite localized content from translation request 924210. by Android Partner Docs <noreply@android.com> - 199872446 add a 1 to the end of researchers twitter handle by Android Partner Docs <noreply@android.com> - 199852050 Change Nexus > Pixel/ Nexus by Danielle Roberts <daroberts@google.com> - 199829857 Devsite localized content from translation request 932861. by Android Partner Docs <noreply@android.com> - 199829853 Devsite localized content from translation request 931901. by Android Partner Docs <noreply@android.com> - 199829847 Devsite localized content from translation request 928418. by Android Partner Docs <noreply@android.com> - 199826612 Add stayres@ to bulletin localization file by Danielle Roberts <daroberts@google.com> PiperOrigin-RevId: 202498507 Change-Id: I3cf1b347a519ecff7960a159cdc57b35306435cf
Diffstat (limited to 'en/devices/architecture/hidl-cpp')
-rw-r--r--en/devices/architecture/hidl-cpp/index.html22
1 files changed, 16 insertions, 6 deletions
diff --git a/en/devices/architecture/hidl-cpp/index.html b/en/devices/architecture/hidl-cpp/index.html
index 28c4aa0a..15098178 100644
--- a/en/devices/architecture/hidl-cpp/index.html
+++ b/en/devices/architecture/hidl-cpp/index.html
@@ -83,7 +83,7 @@ HAL files and is a good reference). When transferring over HALs from
<pre class="prettyprint">
PACKAGE=android.hardware.nfc@1.0
LOC=hardware/interfaces/nfc/1.0/default/
-make hidl-gen -j64
+m -j hidl-gen
hidl-gen -o $LOC -Lc++-impl -randroid.hardware:hardware/interfaces \
-randroid.hidl:system/libhidl/transport $PACKAGE
hidl-gen -o $LOC -Landroidbp-impl -randroid.hardware:hardware/interfaces \
@@ -117,19 +117,29 @@ a binderized service. Example daemon code (for pure binderized service):</p>
<pre class="prettyprint">
int main(int /* argc */, char* /* argv */ []) {
+ // This function must be called before you join to ensure the proper
+ // number of threads are created. The threadpool will never exceed
+ // size one because of this call.
+ ::android::hardware::configureRpcThreadpool(1 /*threads*/, true /*willJoin*/);
+
sp<INfc> nfc = new Nfc();
const status_t status = nfc-&gt;registerAsService();
if (status != ::android::OK) {
return 1; // or handle error
}
- // join pool or do other things
+
+ // Adds this thread to the threadpool, resulting in one total
+ // thread in the threadpool. We could also do other things, but
+ // would have to specify 'false' to willJoin in configureRpcThreadpool.
+ ::android::hardware::joinRpcThreadpool();
+ return 1; // joinRpcThreadpool should never return
}
</pre>
-<p>This daemon should live in <code>$PACKAGE + "-service"</code> (for example,
-<code>android.hardware.nfc@1.0-service</code>). The
-<a href="/security/selinux/device-policy.html">sepolicy</a> for a specific class
-of HALs is the attribute <code>hal_&lt;module&gt;</code> (for instance,
+<p>This daemon usually lives in <code>$PACKAGE + "-service-suffix"</code> (for
+example, <code>android.hardware.nfc@1.0-service</code>), but it could be anywhere.
+The <a href="/security/selinux/device-policy.html">sepolicy</a> for a specific
+class of HALs is the attribute <code>hal_&lt;module&gt;</code> (for instance,
<code>hal_nfc)</code>. This attribute must be applied to the daemon that runs a
particular HAL (if the same process serves multiple HALs, multiple attributes
can be applied to it).</p>