Lines Matching refs:logger
62 static struct ec_response_pd_log *ec_get_log_entry(struct logger_data *logger) in ec_get_log_entry() argument
64 struct cros_ec_dev *ec_dev = logger->ec_dev; in ec_get_log_entry()
68 msg = (struct cros_ec_command *)logger->ec_buffer; in ec_get_log_entry()
170 struct logger_data *logger = container_of(to_delayed_work(work), in cros_usbpd_log_check() local
173 struct device *dev = logger->dev; in cros_usbpd_log_check()
179 r = ec_get_log_entry(logger); in cros_usbpd_log_check()
191 queue_delayed_work(logger->log_workqueue, &logger->log_work, in cros_usbpd_log_check()
199 struct logger_data *logger; in cros_usbpd_logger_probe() local
201 logger = devm_kzalloc(dev, sizeof(*logger), GFP_KERNEL); in cros_usbpd_logger_probe()
202 if (!logger) in cros_usbpd_logger_probe()
205 logger->dev = dev; in cros_usbpd_logger_probe()
206 logger->ec_dev = ec_dev; in cros_usbpd_logger_probe()
208 platform_set_drvdata(pd, logger); in cros_usbpd_logger_probe()
211 INIT_DELAYED_WORK(&logger->log_work, cros_usbpd_log_check); in cros_usbpd_logger_probe()
212 logger->log_workqueue = create_singlethread_workqueue("cros_usbpd_log"); in cros_usbpd_logger_probe()
213 if (!logger->log_workqueue) in cros_usbpd_logger_probe()
216 queue_delayed_work(logger->log_workqueue, &logger->log_work, in cros_usbpd_logger_probe()
224 struct logger_data *logger = platform_get_drvdata(pd); in cros_usbpd_logger_remove() local
226 cancel_delayed_work_sync(&logger->log_work); in cros_usbpd_logger_remove()
227 destroy_workqueue(logger->log_workqueue); in cros_usbpd_logger_remove()
234 struct logger_data *logger = dev_get_drvdata(dev); in cros_usbpd_logger_resume() local
236 queue_delayed_work(logger->log_workqueue, &logger->log_work, in cros_usbpd_logger_resume()
244 struct logger_data *logger = dev_get_drvdata(dev); in cros_usbpd_logger_suspend() local
246 cancel_delayed_work_sync(&logger->log_work); in cros_usbpd_logger_suspend()