Re: [patch 5/6] Convert to use mutexes instead of semaphores



On 8/11/06, Dmitry Torokhov <dtor@xxxxxxxxxxxxx> wrote:
Backlight: convert to use mutexes instead of semaphores


Apparently I missed that several drivers also use bd->sem so they need
to be converted too... But what is it with the drivers:

static void aty128_bl_set_power(struct fb_info *info, int power)
{
mutex_lock(&info->bl_mutex);
up(&info->bl_dev->sem);
info->bl_dev->props->power = power;
__aty128_bl_update_status(info->bl_dev);
down(&info->bl_dev->sem);
mutex_unlock(&info->bl_mutex);
}

Why we are doing up() before down()??? And it is in almost every
driver that uses backlight... Do I need more coffee? [CC-ing bunch of
people trying to get an answer...]

--
Dmitry
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



Relevant Pages

  • Re: This months price for the most useless new Kconfig help text ...
    ... an agenda is not an excuse for bad option descriptions. ... see options for Fusion Message Passing Technology drivers" do not ... More majordomo info at http://vger.kernel.org/majordomo-info.html ... Please read the FAQ at http://www.tux.org/lkml/ ...
    (Linux-Kernel)
  • Re: Linux 2.6.22-rc1
    ... Architecture updates, drivers, filesystems, networking, security, build ... painful as the big fundamental timer changes for 2.6.21, ... More majordomo info at http://vger.kernel.org/majordomo-info.html ... Please read the FAQ at http://www.tux.org/lkml/ ...
    (Linux-Kernel)
  • Re: [patch] e1000=y && e1000e=m regression fix
    ... There is no sense in *ever* showing it as two drivers to users, ... "do you want e1000 support". ... More majordomo info at http://vger.kernel.org/majordomo-info.html ... Please read the FAQ at http://www.tux.org/lkml/ ...
    (Linux-Kernel)
  • Re: [PATCH -mm] fix ipr-use-memory_read_from_buffer.patch
    ... include of string.h from somewhere (like the rest of the SCSI drivers). ... More majordomo info at http://vger.kernel.org/majordomo-info.html ... Please read the FAQ at http://www.tux.org/lkml/ ...
    (Linux-Kernel)
  • Re: Linux 2.6.15-rc4
    ... some drivers will now complain loudly about their nasty mis-use of ... > page remapping, and that migh look scary, but it should all be good, and ... > More majordomo info at http://vger.kernel.org/majordomo-info.html ... > Please read the FAQ at http://www.tux.org/lkml/ ...
    (Linux-Kernel)