Searched defs:bytes (Results 1 - 15 of 15) sorted by relevance

/system/core/libutils/
H A DJenkinsHash.cpp33 uint32_t JenkinsHashMixBytes(uint32_t hash, const uint8_t* bytes, size_t size) { argument
37 uint32_t data = bytes[i] | (bytes[i+1] << 8) | (bytes[i+2] << 16) | (bytes[i+3] << 24);
41 uint32_t data = bytes[i];
42 data |= ((size & 3) > 1) ? (bytes[i+1] << 8) : 0;
43 data |= ((size & 3) > 2) ? (bytes[i+2] << 16) : 0;
H A DBasicHashtable.cpp246 size_t bytes = count * mBucketSize; local
247 SharedBuffer* sb = SharedBuffer::alloc(bytes);
248 LOG_ALWAYS_FATAL_IF(!sb, "Could not allocate %u bytes for hashtable with %u buckets.",
249 uint32_t(bytes), uint32_t(count));
H A DString8.cpp99 const ssize_t bytes = utf16_to_utf8_length(in, len); local
100 if (bytes < 0) {
104 SharedBuffer* buf = SharedBuffer::alloc(bytes+1);
121 const ssize_t bytes = utf32_to_utf8_length(in, len); local
122 if (bytes < 0) {
126 SharedBuffer* buf = SharedBuffer::alloc(bytes+1);
286 const size_t otherLen = other.bytes();
287 if (bytes() == 0) {
304 if (bytes() == 0) {
351 const size_t myLen = bytes();
[all...]
H A DUnicode.cpp58 // indexed by number of bytes in the sequence.
76 * Return number of UTF-8 bytes required for the character. If the character
81 // Figure out how many bytes the result will require.
105 static inline void utf32_codepoint_to_utf8(uint8_t* dstP, char32_t srcChar, size_t bytes) argument
107 dstP += bytes;
108 switch (bytes)
113 case 1: *--dstP = (uint8_t)(srcChar | kFirstByteMark[bytes]);
418 // surrogate pairs are always 4 bytes.
/system/core/libcutils/
H A Ddebugger.c42 ssize_t bytes = read(fd, &ehdr, sizeof(ehdr)); local
44 if (bytes != (ssize_t) sizeof(ehdr) || memcmp(ELFMAG, ehdr, SELFMAG) != 0) {
/system/core/toolbox/upstream-netbsd/lib/libc/gen/
H A Dhumanize_number.c47 humanize_number(char *buf, size_t len, int64_t bytes, argument
90 if (bytes < 0) {
93 if (-bytes < INT64_MAX / 100)
94 bytes *= -100;
96 bytes = -bytes;
103 if (bytes < INT64_MAX / 100)
104 bytes *= 100;
132 for (i = 0; bytes >= max - 50 && i < maxscale; i++)
133 bytes /
[all...]
/system/extras/tests/suspend_stress/
H A Dsuspend_stress.cpp144 ssize_t bytes = read(fd, &fired, sizeof(fired)); local
145 if (bytes < 0) {
148 } else if (bytes < (ssize_t)sizeof(fired)) {
149 fprintf(stderr, "unexpected read from timer fd: %zd\n", bytes);
/system/keymaster/include/keymaster/
H A Dkeymaster_tags.h230 inline keymaster_key_param_t Authorization(TypedTag<KM_BYTES, Tag> tag, const void* bytes, argument
232 return keymaster_param_blob(tag, reinterpret_cast<const uint8_t*>(bytes), bytes_len);
242 inline keymaster_key_param_t Authorization(TypedTag<KM_BIGNUM, Tag> tag, const void* bytes, argument
244 return keymaster_param_blob(tag, reinterpret_cast<const uint8_t*>(bytes), bytes_len);
H A Dauthorization_set.h170 * If the specified bytes-typed \p tag exists, places its value in \p val and returns
205 * Grow the indirect data array to ensure it can contain \p length bytes. Preserves any
222 bool push_back(TypedTag<KM_BYTES, Tag> tag, const void* bytes, size_t bytes_len) { argument
223 return push_back(keymaster_param_blob(tag, static_cast<const uint8_t*>(bytes), bytes_len));
227 bool push_back(TypedTag<KM_BIGNUM, Tag> tag, const void* bytes, size_t bytes_len) { argument
228 return push_back(keymaster_param_blob(tag, static_cast<const uint8_t*>(bytes), bytes_len));
237 bool push_back(TypedTag<Type, Tag> tag, const void* bytes, size_t bytes_len) { argument
238 return push_back(Authorization(tag, bytes, bytes_len));
H A Dkeymaster_defs.h61 KM_TAG_CHUNK_LENGTH = KM_INT | 8, /* AEAD mode minimum decryption chunk size, in bytes. */
430 inline keymaster_key_param_t keymaster_param_blob(keymaster_tag_t tag, const uint8_t* bytes, argument
436 param.blob.data = bytes;
/system/core/include/utils/
H A DString8.h69 inline size_t bytes() const;
281 inline size_t String8::bytes() const function in class:android::String8
/system/extras/memtrack/
H A Dmemtrack.cpp70 ssize_t bytes; local
73 bytes = read(fd_, data_ + len_, max_ - len_);
74 if (bytes == 0 || bytes == -1) {
78 len_ += bytes;
137 ssize_t bytes = read(fd, cmd_name_, sizeof(cmd_name_)); local
139 if (bytes == -1 || bytes == 0) {
/system/core/toolbox/upstream-netbsd/bin/dd/
H A Ddd.h101 uint64_t bytes; /* # of bytes written */ member in struct:__anon245
/system/netd/server/
H A DBandwidthController.cpp607 ALOGE("Invalid bytes value. 1..max_int64.");
718 ALOGE("Invalid bytes value. 1..max_int64.");
776 int BandwidthController::getInterfaceSharedQuota(int64_t *bytes) { argument
777 return getInterfaceQuota("shared", bytes);
780 int BandwidthController::getInterfaceQuota(const char *costName, int64_t *bytes) { argument
795 scanRes = fscanf(fp, "%" SCNd64, bytes);
796 ALOGV("Read quota res=%d bytes=%" PRId64, scanRes, *bytes);
836 int BandwidthController::updateQuota(const char *quotaName, int64_t bytes) { argument
852 fprintf(fp, "%" PRId64"\n", bytes);
857 runIptablesAlertCmd(IptOp op, const char *alertName, int64_t bytes) argument
889 runIptablesAlertFwdCmd(IptOp op, const char *alertName, int64_t bytes) argument
917 setGlobalAlert(int64_t bytes) argument
1000 setSharedAlert(int64_t bytes) argument
1016 setInterfaceAlert(const char *iface, int64_t bytes) argument
1062 setCostlyAlert(const char *costName, int64_t bytes, int64_t *alertBytes) argument
1141 int64_t packets, bytes; local
[all...]
H A DCommandListener.cpp870 int64_t bytes; local
875 int rc = sBandwidthCtrl->getInterfaceSharedQuota(&bytes);
882 asprintf(&msg, "%" PRId64, bytes);
889 int64_t bytes; local
895 int rc = sBandwidthCtrl->getInterfaceQuota(argv[2], &bytes);
901 asprintf(&msg, "%" PRId64, bytes);
909 sendGenericSyntaxError(cli, "setquota <interface> <bytes>");
919 sendGenericSyntaxError(cli, "setquotas <bytes> <interface> ...");
972 sendGenericSyntaxError(cli, "setiquota <interface> <bytes>");
1039 sendGenericSyntaxError(cli, "setglobalalert <bytes>");
[all...]

Completed in 475 milliseconds