ataflop.c (6f8191fdf41d3a53cc1d63fe2234e812c55a0092) ataflop.c (8b9ab62662048a3274361c7e5f64037c2c133e2c)
1// SPDX-License-Identifier: GPL-2.0-only
2/*
3 * drivers/block/ataflop.c
4 *
5 * Copyright (C) 1993 Greg Harp
6 * Atari Support by Bjoern Brauel, Roman Hodek
7 *
8 * Big cleanup Sep 11..14 1994 Roman Hodek:

--- 2017 unchanged lines hidden (view full) ---

2026 if (ataflop_alloc_disk(drive, type))
2027 return;
2028 if (add_disk(unit[drive].disk[type]))
2029 goto cleanup_disk;
2030 unit[drive].registered[type] = true;
2031 return;
2032
2033cleanup_disk:
1// SPDX-License-Identifier: GPL-2.0-only
2/*
3 * drivers/block/ataflop.c
4 *
5 * Copyright (C) 1993 Greg Harp
6 * Atari Support by Bjoern Brauel, Roman Hodek
7 *
8 * Big cleanup Sep 11..14 1994 Roman Hodek:

--- 2017 unchanged lines hidden (view full) ---

2026 if (ataflop_alloc_disk(drive, type))
2027 return;
2028 if (add_disk(unit[drive].disk[type]))
2029 goto cleanup_disk;
2030 unit[drive].registered[type] = true;
2031 return;
2032
2033cleanup_disk:
2034 blk_cleanup_disk(unit[drive].disk[type]);
2034 put_disk(unit[drive].disk[type]);
2035 unit[drive].disk[type] = NULL;
2036}
2037
2038static void atari_floppy_cleanup(void)
2039{
2040 int i;
2041 int type;
2042

--- 15 unchanged lines hidden (view full) ---

2058{
2059 int type;
2060
2061 for (type = 0; type < NUM_DISK_MINORS; type++) {
2062 if (!fs->disk[type])
2063 continue;
2064 if (fs->registered[type])
2065 del_gendisk(fs->disk[type]);
2035 unit[drive].disk[type] = NULL;
2036}
2037
2038static void atari_floppy_cleanup(void)
2039{
2040 int i;
2041 int type;
2042

--- 15 unchanged lines hidden (view full) ---

2058{
2059 int type;
2060
2061 for (type = 0; type < NUM_DISK_MINORS; type++) {
2062 if (!fs->disk[type])
2063 continue;
2064 if (fs->registered[type])
2065 del_gendisk(fs->disk[type]);
2066 blk_cleanup_disk(fs->disk[type]);
2066 put_disk(fs->disk[type]);
2067 }
2068 blk_mq_free_tag_set(&fs->tag_set);
2069}
2070
2071static int __init atari_floppy_init (void)
2072{
2073 int i;
2074 int ret;

--- 125 unchanged lines hidden ---
2067 }
2068 blk_mq_free_tag_set(&fs->tag_set);
2069}
2070
2071static int __init atari_floppy_init (void)
2072{
2073 int i;
2074 int ret;

--- 125 unchanged lines hidden ---