The patch titled Subject: floppy-remove-floppy-specific-o_excl-handling-v2 has been added to the -mm tree. Its filename is floppy-remove-floppy-specific-o_excl-handling-v2.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/SubmitChecklist when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Jiri Kosina <jkosina@xxxxxxx> Subject: floppy-remove-floppy-specific-o_excl-handling-v2 > As we no longer set fd_ref to -1, you should also remove: > > if (UDRS->fd_ref < 0) > UDRS->fd_ref = 0; > else > > from floppy_release(), and the 'out:' section of floppy_open(). > Signed-off-by: Jiri Kosina <jkosina@xxxxxxx> Acked-by: Tejun Heo <tj@xxxxxxxxxx> Acked-by: NeilBrown <neilb@xxxxxxx> Cc: Jens Axboe <axboe@xxxxxxxxx> Cc: Joe Perches <joe@xxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- drivers/block/floppy.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff -puN drivers/block/floppy.c~floppy-remove-floppy-specific-o_excl-handling-v2 drivers/block/floppy.c --- a/drivers/block/floppy.c~floppy-remove-floppy-specific-o_excl-handling-v2 +++ a/drivers/block/floppy.c @@ -3612,9 +3612,7 @@ static int floppy_release(struct gendisk mutex_lock(&floppy_mutex); mutex_lock(&open_lock); - if (UDRS->fd_ref < 0) - UDRS->fd_ref = 0; - else if (!UDRS->fd_ref--) { + if (!UDRS->fd_ref--) { DPRINT("floppy_release with fd_ref == 0"); UDRS->fd_ref = 0; } @@ -3713,10 +3711,8 @@ static int floppy_open(struct block_devi mutex_unlock(&floppy_mutex); return 0; out: - if (UDRS->fd_ref < 0) - UDRS->fd_ref = 0; - else - UDRS->fd_ref--; + UDRS->fd_ref--; + if (!UDRS->fd_ref) opened_bdev[drive] = NULL; out2: _ Subject: Subject: floppy-remove-floppy-specific-o_excl-handling-v2 Patches currently in -mm which might be from jkosina@xxxxxxx are origin.patch linux-next.patch floppy-remove-floppy-specific-o_excl-handling.patch floppy-remove-floppy-specific-o_excl-handling-v2.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html