mirror of
https://github.com/tuxbox-neutrino/libstb-hal.git
synced 2025-08-26 15:02:58 +02:00
- rename lt_debug => hal_debug; it's not only libtriple debugging
Signed-off-by: Thilo Graf <dbt@novatux.de> - debuglevel fixed
This commit is contained in:
@@ -16,9 +16,9 @@
|
||||
#include "init.h"
|
||||
#include "pwrmngr.h"
|
||||
|
||||
#include "lt_debug.h"
|
||||
#define lt_debug(args...) _lt_debug(TRIPLE_DEBUG_INIT, NULL, args)
|
||||
#define lt_info(args...) _lt_info(TRIPLE_DEBUG_INIT, NULL, args)
|
||||
#include "hal_debug.h"
|
||||
#define hal_debug(args...) _hal_debug(HAL_DEBUG_INIT, NULL, args)
|
||||
#define hal_info(args...) _hal_info(HAL_DEBUG_INIT, NULL, args)
|
||||
|
||||
#include <stdio.h>
|
||||
#include <dirent.h>
|
||||
@@ -202,7 +202,7 @@ static void poll_input_devices(void) {
|
||||
int r = poll(fds, nfds, 60000 /* ms */);
|
||||
if (r < 0) {
|
||||
if (errno != EAGAIN) {
|
||||
lt_info("%s: poll(): %m\n", __func__);
|
||||
hal_info("%s: poll(): %m\n", __func__);
|
||||
inmux_thread_running = 0;
|
||||
}
|
||||
return;
|
||||
@@ -243,12 +243,12 @@ void start_inmux_thread(void)
|
||||
{
|
||||
input_device[0].fd = open(input_device[0].name, O_RDWR | O_NONBLOCK); // nevis_ir. This is mandatory.
|
||||
if (input_device[0].fd < 0){
|
||||
lt_info("%s: open(%s): %m\n", __func__, input_device[0].name);
|
||||
hal_info("%s: open(%s): %m\n", __func__, input_device[0].name);
|
||||
return;
|
||||
}
|
||||
if (pthread_create(&inmux_task, 0, inmux_thread, NULL) != 0)
|
||||
{
|
||||
lt_info("%s: inmux thread pthread_create: %m\n", __func__);
|
||||
hal_info("%s: inmux thread pthread_create: %m\n", __func__);
|
||||
inmux_thread_running = 0;
|
||||
return;
|
||||
}
|
||||
@@ -265,8 +265,8 @@ static bool initialized = false;
|
||||
void init_td_api()
|
||||
{
|
||||
if (!initialized)
|
||||
lt_debug_init();
|
||||
lt_info("%s begin, initialized=%d, debug=0x%02x\n", __FUNCTION__, (int)initialized, debuglevel);
|
||||
hal_debug_init();
|
||||
hal_info("%s begin, initialized=%d, debug=0x%02x\n", __FUNCTION__, (int)initialized, debuglevel);
|
||||
if (!initialized)
|
||||
{
|
||||
cCpuFreqManager f;
|
||||
@@ -279,7 +279,7 @@ void init_td_api()
|
||||
struct dmx_pes_filter_params p;
|
||||
int dmx = open("/dev/dvb/adapter0/demux0", O_RDWR|O_CLOEXEC);
|
||||
if (dmx < 0)
|
||||
lt_info("%s: ERROR open /dev/dvb/adapter0/demux0 (%m)\n", __func__);
|
||||
hal_info("%s: ERROR open /dev/dvb/adapter0/demux0 (%m)\n", __func__);
|
||||
else
|
||||
{
|
||||
memset(&p, 0, sizeof(p));
|
||||
@@ -295,12 +295,12 @@ void init_td_api()
|
||||
else
|
||||
reopen_input_devices();
|
||||
initialized = true;
|
||||
lt_info("%s end\n", __FUNCTION__);
|
||||
hal_info("%s end\n", __FUNCTION__);
|
||||
}
|
||||
|
||||
void shutdown_td_api()
|
||||
{
|
||||
lt_info("%s, initialized = %d\n", __FUNCTION__, (int)initialized);
|
||||
hal_info("%s, initialized = %d\n", __FUNCTION__, (int)initialized);
|
||||
if (initialized) {
|
||||
stop_inmux_thread();
|
||||
close_input_devices();
|
||||
|
Reference in New Issue
Block a user