c
void thermal_debug_tz_remove(struct thermal_zone_device *tz)
{
    if (!tz)
        return;

    struct thermal_debugfs *thermal_dbg;
    
    if (!(thermal_dbg = tz->debugfs))
        return;

    mutex_lock(&thermal_dbg->lock);
    // ... rest of the function
}
