Re: [Patch][RFC] st: provide tape statistics via sysfs

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

 



On Fri, 2013-02-22 at 02:11 +0000, Seymour, Shane M wrote:
> First forgive me for using outlook for this, if there are any issues with what I sent let me know and I'll send it again from gmail. This is also my first attempt at a kernel patch so please be gentle.
> 
> This patch was written to enable tape statistics via sysfs for the dt
> driver based on kernel 3.8.0-rc6. It creates two new files in sysfs
> and is based on work done previously in 2005 by Kai Mäkisara. Any
> feedback would be greatly appreciated.

I'm afraid we can't do it the way you're proposing.  files in sysfs must
conform to the one value per file rule (so we avoid the ABI nastiness
that plagues /proc).  You can create a stat directory with a bunch of
files, but not a single file that gives all values.

> Assuming sysfs is mounted at /sys the first file
> is /sys/bus/scsi/drivers/st/drives which gives a single number
> indicating what the largest tape drive instance assigned by st_probe
> in the st module is. If it's 4 it possible that st0, st1, st2, and st3
> exist on the system. Since tape drives can later be disconnected they
> don't have to exist, the count is a hint so it's possible to gather
> statistics in a loop with an upper bound. This makes it easier in
> iostat to gather statistcs.

I don't really get why you need this.  What's wrong with getting the
exact information from /sys/class/scsi_tape?

James


--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux