Home
last modified time | relevance | path

Searched refs:severity (Results 1 – 23 of 23) sorted by relevance

/system/libbase/
Dlogging_test.cpp130 #define CHECK_WOULD_LOG_DISABLED(severity) \ argument
131 static_assert(android::base::severity < android::base::FATAL, "Bad input"); \
132 for (size_t i = static_cast<size_t>(android::base::severity) + 1; \
137 EXPECT_FALSE(WOULD_LOG(severity)) << i; \
141 EXPECT_FALSE(WOULD_LOG(::android::base::severity)) << i; \
145 #define CHECK_WOULD_LOG_ENABLED(severity) \ argument
147 i <= static_cast<size_t>(android::base::severity); \
151 EXPECT_TRUE(WOULD_LOG(severity)) << i; \
155 EXPECT_TRUE(WOULD_LOG(::android::base::severity)) << i; \
212 static std::string make_log_pattern(android::base::LogSeverity severity, in make_log_pattern() argument
[all …]
Dlogging.cpp175 static int32_t LogSeverityToPriority(LogSeverity severity) { in LogSeverityToPriority() argument
176 switch (severity) { in LogSeverityToPriority()
238 static void KernelLogLine(const char* msg, int length, android::base::LogSeverity severity, in KernelLogLine() argument
258 int level = kLogSeverityToKernelLogLevel[severity]; in KernelLogLine()
276 void KernelLogger(android::base::LogId, android::base::LogSeverity severity, const char* tag, in KernelLogger() argument
278 SplitByLines(full_message, KernelLogLine, severity, tag); in KernelLogger()
282 void StderrLogger(LogId, LogSeverity severity, const char* tag, const char* file, unsigned int line, in StderrLogger() argument
293 StderrOutputGenerator(now, getpid(), GetThreadId(), severity, tag, file, line, message); in StderrLogger()
298 void StdioLogger(LogId, LogSeverity severity, const char* /*tag*/, const char* /*file*/, in StdioLogger() argument
300 if (severity >= WARNING) { in StdioLogger()
[all …]
Dlogging_splitters.h48 static void SplitByLogdChunks(LogId log_id, LogSeverity severity, const char* tag, const char* file, in SplitByLogdChunks() argument
62 bool add_file = file != nullptr && (severity == FATAL || severity == FATAL_WITHOUT_ABORT); in SplitByLogdChunks()
74 log_function(log_id, severity, tag, logd_chunk); in SplitByLogdChunks()
126 log_function(log_id, severity, tag, logd_chunk); in SplitByLogdChunks()
128 log_function(log_id, severity, tag, msg); in SplitByLogdChunks()
149 LogSeverity severity, const char* tag, const char* file, in StderrOutputGenerator() argument
157 char severity_char = log_characters[severity]; in StderrOutputGenerator()
/system/libbase/include/android-base/
Dlogging.h163 #define SEVERITY_LAMBDA(severity) ([&]() { \ argument
171 return (severity); }())
186 #define MUST_LOG_MESSAGE(severity) (SEVERITY_LAMBDA(severity) == ::android::base::FATAL) argument
190 #define MUST_LOG_MESSAGE(severity) false argument
195 #define WOULD_LOG(severity) \ argument
196 (UNLIKELY(::android::base::ShouldLog(SEVERITY_LAMBDA(severity), _LOG_TAG_INTERNAL)) || \
197 MUST_LOG_MESSAGE(severity))
206 #define LOG_STREAM(severity) \ argument
207 ::android::base::LogMessage(__FILE__, __LINE__, SEVERITY_LAMBDA(severity), _LOG_TAG_INTERNAL, \
215 #define LOG(severity) LOGGING_PREAMBLE(severity) && LOG_STREAM(severity) argument
[all …]
/system/core/adb/
Dadb_trace.cpp42 void AdbLogger(android::base::LogId id, android::base::LogSeverity severity, in AdbLogger() argument
45 android::base::StderrLogger(id, severity, tag, file, line, message); in AdbLogger()
54 if (severity >= android::base::INFO) { in AdbLogger()
55 gLogdLogger(id, severity, tag, file, line, message); in AdbLogger()
/system/connectivity/wifilogd/
Dprotocol.h87 severity = new_severity; in set_severity()
93 MessageSeverity severity; member
/system/core/fs_mgr/libsnapshot/
Dsnapshot_fuzz.cpp184 void FatalOnlyLogger(LogId logid, LogSeverity severity, const char* tag, const char* file, in FatalOnlyLogger() argument
186 if (severity == LogSeverity::FATAL) { in FatalOnlyLogger()
187 StderrLogger(logid, severity, tag, file, line, message); in FatalOnlyLogger()
191 StderrLogger(logid, severity, tag, __FILE__, __LINE__, in FatalOnlyLogger()
194 StderrLogger(logid, severity, tag, __FILE__, __LINE__, "Current corpus is nullptr."); in FatalOnlyLogger()
198 StderrLogger(logid, severity, tag, __FILE__, __LINE__, in FatalOnlyLogger()
201 StderrLogger(logid, severity, tag, __FILE__, __LINE__, content.c_str()); in FatalOnlyLogger()
/system/connectivity/wifilogd/tests/
Dprotocol_unittest.cpp67 EXPECT_EQ(3U, offsetof(AsciiMessage, severity)); in TEST()
68 EXPECT_EQ(1U, sizeof(AsciiMessage::severity)); in TEST()
/system/update_engine/
Dlogging_android.cc219 bool RedirectToLiblog(int severity, in RedirectToLiblog() argument
225 (severity < 0) ? ANDROID_LOG_VERBOSE : ANDROID_LOG_UNKNOWN; in RedirectToLiblog()
226 switch (severity) { in RedirectToLiblog()
/system/core/liblog/tests/
Dliblog_global_state.cpp34 auto LoggerFunction = [&](LogId log_id, LogSeverity severity, const char* tag, const char* file, in TEST()
38 EXPECT_EQ(expected_severity, severity); in TEST()
85 auto LoggerFunction = [&](LogId log_id, LogSeverity severity, const char* tag, const char* file, in TEST()
89 EXPECT_EQ(WARNING, severity); in TEST()
/system/core/toolbox/
Dmodprobe.cpp78 void MyLogger(android::base::LogId id, android::base::LogSeverity severity, const char* tag, in MyLogger() argument
80 android::base::StdioLogger(id, severity, tag, file, line, message); in MyLogger()
82 android::base::KernelLogger(id, severity, tag, file, line, message); in MyLogger()
/system/core/logd/
Dmain.cpp232 argv, [](android::base::LogId log_id, android::base::LogSeverity severity, in main()
236 android::base::KernelLogger(log_id, severity, "logd", file, line, in main()
239 android::base::KernelLogger(log_id, severity, "logd", file, line, message); in main()
/system/linkerconfig/
Dmain.cc297 void operator()(android::base::LogId id, android::base::LogSeverity severity, in operator ()()
300 logd(id, severity, tag, file, line, message); in operator ()()
301 KernelLogger(id, severity, tag, file, line, message); in operator ()()
/system/extras/simpleperf/
Dcommand.cpp212 static void StderrLogger(android::base::LogId, android::base::LogSeverity severity, in StderrLogger() argument
215 char severity_char = log_characters[severity]; in StderrLogger()
263 android::base::ScopedLogSeverity severity(log_severity); in RunSimpleperfCmd() local
Dutils.cpp306 bool GetLogSeverity(const std::string& name, android::base::LogSeverity* severity) { in GetLogSeverity() argument
309 *severity = it->second; in GetLogSeverity()
316 android::base::LogSeverity severity = android::base::GetMinimumLogSeverity(); in GetLogSeverityName() local
318 if (severity == pair.second) { in GetLogSeverityName()
Dgtest_main.cpp99 android::base::ScopedLogSeverity severity(log_severity); in main() local
Dreport_lib_interface.cpp204 android::base::LogSeverity severity; in SetLogSeverity() local
205 if (!GetLogSeverity(log_level, &severity)) { in SetLogSeverity()
210 log_severity_.reset(new android::base::ScopedLogSeverity(severity)); in SetLogSeverity()
Dutils.h144 bool GetLogSeverity(const std::string& name, android::base::LogSeverity* severity);
/system/core/fs_mgr/
Dfs_mgr_remount.cpp88 void MyLogger(android::base::LogId id, android::base::LogSeverity severity, const char* tag, in MyLogger() argument
90 if (verbose || severity == android::base::ERROR || message[0] != '[') { in MyLogger()
94 logd(id, severity, tag, file, line, message); in MyLogger()
/system/core/init/
Dselinux.cpp551 android::base::LogSeverity severity = android::base::ERROR; in SelinuxKlogCallback() local
553 severity = android::base::WARNING; in SelinuxKlogCallback()
555 severity = android::base::INFO; in SelinuxKlogCallback()
568 android::base::KernelLogger(android::base::MAIN, severity, "selinux", nullptr, 0, buf); in SelinuxKlogCallback()
Dbuiltins.cpp1041 android::base::LogSeverity severity; in do_loglevel() local
1043 case 7: severity = android::base::DEBUG; break; in do_loglevel()
1044 case 6: severity = android::base::INFO; break; in do_loglevel()
1046 case 4: severity = android::base::WARNING; break; in do_loglevel()
1047 case 3: severity = android::base::ERROR; break; in do_loglevel()
1050 case 0: severity = android::base::FATAL; break; in do_loglevel()
1054 android::base::SetMinimumLogSeverity(severity); in do_loglevel()
Dutil.cpp738 auto second_stage_logger = [](android::base::LogId log_id, android::base::LogSeverity severity, in InitSecondStageLogging()
750 android::base::KernelLogger(log_id, severity, tag, file, line, message); in InitSecondStageLogging()
/system/extras/partition_tools/
Dlpadd.cc414 static void ErrorLogger(android::base::LogId, android::base::LogSeverity severity, const char*, in ErrorLogger() argument
416 if (severity < android::base::WARNING) { in ErrorLogger()