qcacmn: Change fwlogs API for smartlogs
Add function pointers for calling smartlogs init and deinit. CRs-Fixed: 2008290 Change-Id: I4734e490394a24f5a39eb50f3ac386ad99834cb3
This commit is contained in:

committed by
nshrivas

父節點
420a4425dc
當前提交
ad5e0bd66f
@@ -47,12 +47,13 @@ int fwdbg_fw_handler(struct common_dbglog_handle *dbg_handle, ol_scn_t soc,
|
||||
}
|
||||
|
||||
int fwdbg_parse_debug_logs(struct common_dbglog_handle *dbg_handle,
|
||||
const char *name, uint8_t *datap, uint16_t len, void *context)
|
||||
ol_scn_t soc, uint8_t *datap,
|
||||
uint16_t len, void *context)
|
||||
{
|
||||
struct dbglog_info *dbg_info = handle2info(dbg_handle);
|
||||
|
||||
if (dbg_info->ops->dbglog_parse_debug_logs)
|
||||
return dbg_info->ops->dbglog_parse_debug_logs(name,
|
||||
return dbg_info->ops->dbglog_parse_debug_logs(soc,
|
||||
datap, len, context);
|
||||
|
||||
return 0;
|
||||
@@ -139,3 +140,32 @@ void fwdbg_set_report_size(struct common_dbglog_handle *dbg_handle,
|
||||
|
||||
}
|
||||
|
||||
int fwdbg_smartlog_init(struct common_dbglog_handle *dbg_handle, void *soc)
|
||||
{
|
||||
struct dbglog_info *dbg_info = handle2info(dbg_handle);
|
||||
|
||||
if (dbg_info->ops->smartlog_init)
|
||||
return dbg_info->ops->smartlog_init(soc);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void fwdbg_smartlog_deinit(struct common_dbglog_handle *dbg_handle, void *sc)
|
||||
{
|
||||
struct dbglog_info *dbg_info = handle2info(dbg_handle);
|
||||
|
||||
if (dbg_info->ops->smartlog_deinit)
|
||||
dbg_info->ops->smartlog_deinit(sc);
|
||||
}
|
||||
|
||||
ssize_t fwdbg_smartlog_dump(struct common_dbglog_handle *dbg_handle,
|
||||
struct device *dev,
|
||||
struct device_attribute *attr, char *buf)
|
||||
{
|
||||
struct dbglog_info *dbg_info = handle2info(dbg_handle);
|
||||
|
||||
if (dbg_info->ops->smartlog_dump)
|
||||
return dbg_info->ops->smartlog_dump(dev, attr, buf);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user