> --- diff/drivers/md/dm.c 2003-05-21 11:50:15.000000000 +0100
> +++ source/drivers/md/dm.c 2003-06-09 15:05:02.000000000 +0100
> @@ -546,21 +546,22 @@
>
> spin_lock(&_minor_lock);
> if (!test_and_set_bit(minor, _minor_bits))
> - r = minor;
> + r = 0;
> spin_unlock(&_minor_lock);
>
> return r;
> }
>
> -static int next_free_minor(void)
> +static int next_free_minor(unsigned int *minor)
> {
> - int minor, r = -EBUSY;
> + unsigned int m, r = -EBUSY;
Looks like "r" should still be signed.
> spin_lock(&_minor_lock);
> - minor = find_first_zero_bit(_minor_bits, MAX_DEVICES);
> - if (minor != MAX_DEVICES) {
> - set_bit(minor, _minor_bits);
> - r = minor;
> + m = find_first_zero_bit(_minor_bits, MAX_DEVICES);
> + if (m != MAX_DEVICES) {
> + set_bit(m, _minor_bits);
> + *minor = m;
> + r = 0;
> }
> spin_unlock(&_minor_lock);
>
-- Kevin Corry kevcorry@us.ibm.com http://evms.sourceforge.net/- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/