/system/bt/osi/src/ |
H A D | eager_reader.c | 61 static bool has_byte(const eager_reader_t *reader); 122 void eager_reader_free(eager_reader_t *reader) { argument 123 if (!reader) 126 eager_reader_unregister(reader); 129 if (reader->inbound_read_object) 130 reactor_unregister(reader->inbound_read_object); 132 if (reader->bytes_available_fd != INVALID_FD) 133 close(reader->bytes_available_fd); 137 if (reader->current_buffer) 138 reader 145 eager_reader_register(eager_reader_t *reader, reactor_t *reactor, eager_reader_cb read_cb, void *context) argument 158 eager_reader_unregister(eager_reader_t *reader) argument 168 eager_reader_read(eager_reader_t *reader, uint8_t *buffer, size_t max_size, bool block) argument 214 eager_reader_get_read_thread(const eager_reader_t *reader) argument 219 has_byte(const eager_reader_t *reader) argument 236 eager_reader_t *reader = (eager_reader_t *)context; local 269 eager_reader_t *reader = (eager_reader_t *)context; local [all...] |
/system/bt/osi/include/ |
H A D | eager_reader.h | 31 typedef void (*eager_reader_cb)(eager_reader_t *reader, void *context); 33 // Creates a new eager reader object, which pulls data from |fd_to_read| into 46 // Frees an eager reader object, and associated internal resources. 47 // |reader| may be NULL. 48 void eager_reader_free(eager_reader_t *reader); 50 // Registers |reader| with the |reactor|. When the reader has data 52 // Neither |reader|, nor |reactor|, nor |read_cb| may be NULL. |context| may be NULL. 53 void eager_reader_register(eager_reader_t *reader, reactor_t *reactor, eager_reader_cb read_cb, void *context); 55 // Unregisters |reader| fro [all...] |
/system/core/logd/ |
H A D | LogListener.h | 25 LogReader *reader; member in class:LogListener 28 LogListener(LogBuffer *buf, LogReader *reader);
|
H A D | LogAudit.h | 25 LogReader *reader; member in class:LogAudit 30 LogAudit(LogBuffer *buf, LogReader *reader, int fdDmesg);
|
H A D | LogKlog.h | 28 LogReader *reader; member in class:LogKlog 44 LogKlog(LogBuffer *buf, LogReader *reader, int fdWrite, int fdRead, bool auditd);
|
H A D | LogListener.cpp | 31 LogListener::LogListener(LogBuffer *buf, LogReader *reader) : argument 34 reader(reader) { 104 reader->notifyNewLog();
|
H A D | CommandListener.h | 33 CommandListener(LogBuffer *buf, LogReader *reader, LogListener *swl); 45 ShutdownCmd(LogBuffer *buf, LogReader *reader, LogListener *swl);
|
H A D | FlushCommand.cpp | 25 FlushCommand::FlushCommand(LogReader &reader, argument 31 mReader(reader), 40 // log reader socket. Here we manage and associated the reader
|
H A D | LogTimes.cpp | 26 LogTimeEntry::LogTimeEntry(LogReader &reader, SocketClient *client, argument 35 mReader(reader), 83 LogReader &reader = me->mReader; local 84 LastLogTimes × = reader.logbuf().mTimes; 97 reader.release(client); 111 prctl(PR_SET_NAME, "logd.reader.per");
|
H A D | main.cpp | 328 // transitory per-client threads are created for each reader. 399 // socket connection, and as a reader lock on a range of log 418 LogReader *reader = new LogReader(logBuf); local 419 if (reader->startListener()) { 427 LogListener *swl = new LogListener(logBuf, reader); 436 CommandListener *cl = new CommandListener(logBuf, reader, swl); 450 al = new LogAudit(logBuf, reader, dmesg ? fdDmesg : -1); 455 kl = new LogKlog(logBuf, reader, fdDmesg, fdPmesg, al != NULL);
|
H A D | LogAudit.cpp | 40 LogAudit::LogAudit(LogBuffer *buf, LogReader *reader, int fdDmesg) : argument 43 reader(reader), 233 reader->notifyNewLog();
|
H A D | LogTimes.h | 51 LogTimeEntry(LogReader &reader, SocketClient *client, bool nonBlock,
|
H A D | LogKlog.cpp | 175 LogKlog::LogKlog(LogBuffer *buf, LogReader *reader, int fdWrite, int fdRead, bool auditd) : argument 178 reader(reader), 643 reader->notifyNewLog();
|
H A D | CommandListener.cpp | 35 CommandListener::CommandListener(LogBuffer *buf, LogReader * /*reader*/, 50 CommandListener::ShutdownCmd::ShutdownCmd(LogBuffer *buf, LogReader *reader, argument 54 mReader(*reader),
|
H A D | LogBufferElement.cpp | 193 uint64_t LogBufferElement::flushTo(SocketClient *reader, LogBuffer *parent) { argument 223 uint64_t retval = reader->sendDatav(iovec, 2) ? FLUSH_ERROR : mSequence;
|
H A D | LogBuffer.cpp | 336 // First there is a prep phase where we discover the reader region lock that 368 // lock is causing us to buffer too much in the logs to help the reader(s), 369 // and will tell the slowest reader thread to skip log entries, and if 370 // persistent and hits a further threshold, kill the reader thread. 607 // kick a misbehaving log reader client off the island 625 // Do not save the whitelist if we are reader range limited 638 // kick a misbehaving log reader client off the island 690 SocketClient *reader, const uint64_t start, bool privileged, 694 uid_t uid = reader->getUid(); 739 max = element->flushTo(reader, thi 689 flushTo( SocketClient *reader, const uint64_t start, bool privileged, int (*filter)(const LogBufferElement *element, void *arg), void *arg) argument [all...] |
/system/bt/osi/test/ |
H A D | eager_reader_test.cpp | 87 static void expect_data(eager_reader_t *reader, void *context) { argument 93 EXPECT_EQ((size_t)1, eager_reader_read(reader, &byte, 1, true)); 100 static void expect_data_multibyte(eager_reader_t *reader, void *context) { argument 107 int bytes_read = eager_reader_read(reader, buffer, bytes_to_read, false); 118 eager_reader_t *reader = eager_reader_new(pipefd[0], &allocator_malloc, BUFFER_SIZE, SIZE_MAX, "test_thread"); local 119 ASSERT_TRUE(reader != NULL); 120 eager_reader_free(reader); 124 eager_reader_t *reader = eager_reader_new(pipefd[0], &allocator_malloc, BUFFER_SIZE, SIZE_MAX, "test_thread"); local 127 eager_reader_register(reader, thread_get_reactor(read_thread), expect_data, (void *)small_data); 132 eager_reader_free(reader); 137 eager_reader_t *reader = eager_reader_new(pipefd[0], &allocator_malloc, BUFFER_SIZE, SIZE_MAX, "test_thread"); local [all...] |
/system/extras/simpleperf/ |
H A D | cmd_record_test.cpp | 63 std::unique_ptr<RecordFileReader> reader = RecordFileReader::CreateInstance("perf.data"); local 64 ASSERT_TRUE(reader != nullptr); 65 std::vector<std::unique_ptr<const Record>> records = reader->DataSection(); 82 std::unique_ptr<RecordFileReader> reader = RecordFileReader::CreateInstance("perf.data"); local 83 ASSERT_TRUE(reader != nullptr); 84 const FileHeader* file_header = reader->FileHeader(); 87 ASSERT_GT(reader->FeatureSectionDescriptors().size(), 0u);
|
H A D | record_file_test.cpp | 70 std::unique_ptr<RecordFileReader> reader = RecordFileReader::CreateInstance(filename); local 71 ASSERT_TRUE(reader != nullptr); 72 const FileHeader* file_header = reader->FileHeader(); 74 std::vector<const FileAttr*> attrs = reader->AttrSection(); 77 std::vector<uint64_t> ids = reader->IdsForAttr(attrs[0]); 81 std::vector<std::unique_ptr<const Record>> records = reader->DataSection(); 88 std::vector<SectionDesc> sections = reader->FeatureSectionDescriptors(); 91 reinterpret_cast<const perf_event_header*>(reader->DataAtOffset(sections[0].offset)); 96 ASSERT_TRUE(reader->Close());
|
H A D | environment.cpp | 41 LineReader reader(fp); 43 if ((line = reader.ReadLine()) != nullptr) { 83 LineReader reader(fp); 85 while ((line = reader.ReadLine()) != nullptr) { 87 char name[reader.MaxLineSize()]; 88 char module[reader.MaxLineSize()]; 148 LineReader reader(fp); 150 while ((line = reader.ReadLine()) != nullptr) { 152 char name[reader.MaxLineSize()]; 259 LineReader reader(f [all...] |
H A D | record_file.cpp | 327 auto reader = std::unique_ptr<RecordFileReader>(new RecordFileReader(filename, fd)); local 328 if (!reader->MmapFile()) { 331 return reader;
|
/system/bt/hci/src/ |
H A D | hci_hal_mct.c | 47 static void event_event_stream_has_bytes(eager_reader_t *reader, void *context); 48 static void event_acl_stream_has_bytes(eager_reader_t *reader, void *context); 97 LOG_ERROR("%s unable to create eager reader for the event uart serial port.", __func__); 103 LOG_ERROR("%s unable to create eager reader for the acl-in uart serial port.", __func__); 181 static void event_event_stream_has_bytes(UNUSED_ATTR eager_reader_t *reader, UNUSED_ATTR void *context) { argument 185 static void event_acl_stream_has_bytes(UNUSED_ATTR eager_reader_t *reader, UNUSED_ATTR void *context) { argument
|
H A D | hci_hal_h4.c | 54 static void event_uart_has_bytes(eager_reader_t *reader, void *context); 87 LOG_ERROR("%s unable to create eager reader for the uart serial port.", __func__); 220 static void event_uart_has_bytes(eager_reader_t *reader, UNUSED_ATTR void *context) { argument 225 if (eager_reader_read(reader, &type_byte, 1, true) == 0) {
|