Need part_in_flight() to be non-static

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Christoph,

I have a Memblaze Gen2 PCIe SSD card (quite old), whose driver source
code references part_in_flight(), but recently I find the code does not
compile because this function is static in 5.7-rc1 by following change,

commit 6005771c17db56b6a9acc12bd084134191560e18
Author: Christoph Hellwig <hch@xxxxxx>
Date:   Wed Mar 25 16:48:36 2020 +0100

    block: mark part_in_flight and part_in_flight_rw static

    Signed-off-by: Christoph Hellwig <hch@xxxxxx>
    Signed-off-by: Jens Axboe <axboe@xxxxxxxxx>

The driver is open source, but not merged upstream and out of
maintenance now. Memblaze lent them to me for years, I just update the
kabi part to make it just work, and use them to test upstream md and
bcache code time to time.

The code piece where part_in_flight() is referenced is,

#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 24)
inline void part_round_stats_single(int cpu, struct hd_struct
*part,unsigned long now)
{
        if (now == part->stamp)
                return;

        if (part_in_flight(part)) {
                __part_stat_add(cpu, part, time_in_queue,
                                part_in_flight(part) * (now - part->stamp));
                __part_stat_add(cpu, part, io_ticks, (now - part->stamp));
        }
        part->stamp = now;
}

Is is possible to convert part_in_flight() to be non-static back ? If it
is not possible, is there any other routines I can use to make
part_round_stats_single() working ?

Thanks.

Coly Li



[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux