All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Seymour, Shane M" <shane.seymour@hpe.com>
To: "\"Kai Mäkisara (Kolumbus)\"" <kai.makisara@kolumbus.fi>
Cc: Laurence Oberman <loberman@redhat.com>,
	Emmanuel Florac <eflorac@intellique.com>,
	Laurence Oberman <oberman.l@gmail.com>,
	"linux-scsi@vger.kernel.org" <linux-scsi@vger.kernel.org>
Subject: RE: What partition should the MTMKPART argument specify? Was: Re: st driver doesn't seem to grok LTO partitioning
Date: Fri, 22 Jan 2016 02:10:03 +0000	[thread overview]
Message-ID: <DDB9C85B850785449757F9914A034FCB44517327@G4W3219.americas.hpqcorp.net> (raw)
In-Reply-To: <0840949A-970D-43FB-A691-E2F8AC2A0804@kolumbus.fi>

Hi Kai,

> -----Original Message-----
> From: linux-scsi-owner@vger.kernel.org [mailto:linux-scsi-
> owner@vger.kernel.org] On Behalf Of "Kai Mäkisara (Kolumbus)"
> Sent: Friday, January 22, 2016 7:59 AM
> To: Seymour, Shane M
> Cc: Laurence Oberman; Emmanuel Florac; Laurence Oberman; linux-
> scsi@vger.kernel.org
> Subject: What partition should the MTMKPART argument specify? Was: Re:
> st driver doesn't seem to grok LTO partitioning
> 
> 
> > On 15.1.2016, at 2.21, Seymour, Shane M <shane.seymour@hpe.com>
> wrote:
> >
> > Unfortunately I'm unable to lay my hands on an LTO 5 tape drive so I'm not
> able to test that it works either. If it helps at all I can test in the negative and
> make sure that for an LTO 3 drive it fails gracefully but that's about it at the
> moment.
> 
> Thanks for all testers and those who attempted to test. The latest patch
> applies the standard quite strictly and I think it should work with most drives.
> The implementation can be fixed later if problems are found.
> 
> However, before making the final patch, we should decide which partition
> the specified size should apply to. For the SCSI level <=2 it applies to partition
> 1. For other drives we may have some freedom to “tune” the definition. The
> size should apply to the partition the users expect it to apply.

I'd argue for consistency here in the current interface and that it should 
apply in the same way more on that below.

> 
> The current documentation says "the argument gives in megabytes the size
> of partition 1 that is physically the first partition of the tape”. The
> documentation I have found for current drives (HP and IBM LTO, IBM 3592,
> Storagetek T1000) all number the partitions sequentially from the start of the
> tape. The access time for any partition is probably about the same when
> wrapwise partitioning is used. It does matter with linear partitioning.
> Unfortunately, the standards leave the numbering to the implementor.
> 
> Partitioning with two partitions is used for storing index in a small partition
> and use the rest of the tape for data. In this case, it is probably natural to
> specify the size of the index. The LTFS definition supports index in any
> partition. The open source code I have seen seem to default to index in
> partition 0.
> 
> The HP and IBM LTO default partitioning (FDP=1) specifies two wraps
> (minimum) to partition 1 and the rest to 0.

It may be worth noting (if you're going to update any documentation)
that isn't 100% accurate. You actually get one wrap in partition 1 and the
rest minus one wrap into partition 0. There is one wrap used as a guard
between the two partitions. The size given to a partition is rounded up
to the size of a wrap as well.

See https://docs.oracle.com/cd/E21419_04/en/LTO5_Vol3_E5b/LTO5_Vol3_E5b.pdf

Page 100 where it gives examples of how partition sizes are calculated on HP LTO5 drives.

> 
> There seem to be lot of arguments supporting both possible choices. Should
> we use the existing definition (1) or change it for the drives supporting SCSI
> level >= 3 (or supporting FORMAT MEDIUM)? The definition can’t be
> changed later. This is why we should make a good decision.
> 
> Opinions?

How about using the fact the size is signed to indicate one slightly different
thing? I'm not sure if you'd call this using or abusing the fact that it's signed.

Make the default behavior for a positive size the same as the current
behavior for SCSI-2 (size applies to partition 1). If the size is negative then
the absolute value of the size applies to partition 0. That provides some
flexibility in choosing which partition the size applies to if it worked that
way for all devices.

With that you also get consistent behavior between tape drives without
having to know if the size will apply to partition 0 or partition 1 based on
the tape technology and you get the benefit of being able to set an
explicit size for partition 0 or partition 1.

You could overload the value of 0 as well to use FDP to choose the sizes
for the partitions (assuming 0 doesn't already have a side effect in
the code). Then you get whatever the tape drive wants to do.

Thanks
Shane

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

  parent reply	other threads:[~2016-01-22  2:10 UTC|newest]

Thread overview: 73+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20151218170644.24167419@harpe.intellique.com>
2015-12-21 12:46 ` st driver doesn't seem to grok LTO partitioning Emmanuel Florac
2015-12-21 17:25   ` "Kai Mäkisara (Kolumbus)"
     [not found]     ` <20151221185759.38dd21d6@harpe.intellique.com>
2015-12-21 18:57       ` "Kai Mäkisara (Kolumbus)"
2015-12-22  5:51         ` Seymour, Shane M
2015-12-22  9:59           ` Emmanuel Florac
     [not found]           ` <CAAzz28i5=oz_BmcoEC2ApLN9zj_F4aDmGkCXkXaS48HR_Ockew@mail.gmail.com>
2015-12-22 10:04             ` Emmanuel Florac
2015-12-22 10:31               ` Laurence Oberman
2015-12-25 15:53         ` Kai Makisara
2015-12-25 17:47           ` Emmanuel Florac
2015-12-29 16:14           ` Emmanuel Florac
2015-12-29 16:58           ` Emmanuel Florac
2015-12-29 17:46             ` "Kai Mäkisara (Kolumbus)"
2015-12-29 17:58               ` Emmanuel Florac
     [not found]               ` <20151229191347.2e0e5f0e@harpe.intellique.com>
2015-12-30 17:54                 ` Kai Makisara
2015-12-30 18:33                   ` Emmanuel Florac
2015-12-30 19:21                     ` "Kai Mäkisara (Kolumbus)"
2015-12-30 21:24                       ` Emmanuel Florac
2015-12-31 16:08                         ` "Kai Mäkisara (Kolumbus)"
2016-01-04 10:22                           ` Kai Makisara
2016-01-04 10:54                             ` Emmanuel Florac
2016-01-04 11:05                             ` Emmanuel Florac
2016-01-04 11:46                             ` Emmanuel Florac
     [not found]                               ` <CAAzz28gW69rB-6h2fwxtwnTj5h7HZcn2qkJdx2GTgu3Y8SDNqQ@mail.gmail.com>
2016-01-04 15:32                                 ` Emmanuel Florac
     [not found]                               ` <CAAzz28iCoG-rjnL7EsjHXA7UtRJSCEXuwL3+27ZBo7fckcBAfg@mail.gmail.com>
2016-01-05 21:55                                 ` Laurence Oberman
2016-01-06 15:10                                   ` Emmanuel Florac
2016-01-06 15:23                                     ` Laurence Oberman
2016-01-06 15:25                                       ` Laurence Oberman
2016-01-06 15:32                                         ` Laurence Oberman
2016-01-06 15:48                                           ` Douglas Gilbert
2016-01-06 15:54                                             ` Laurence Oberman
2016-01-06 16:07                                       ` Emmanuel Florac
2016-01-14 20:12                                         ` Laurence Oberman
2016-01-15  0:21                                           ` Seymour, Shane M
2016-01-21 20:58                                             ` What partition should the MTMKPART argument specify? Was: " "Kai Mäkisara (Kolumbus)"
2016-01-21 22:06                                               ` Laurence Oberman
2016-01-22  2:10                                               ` Seymour, Shane M [this message]
2016-01-22  3:31                                                 ` Seymour, Shane M
2016-01-22 11:24                                                 ` Emmanuel Florac
2016-01-22 11:50                                                 ` Emmanuel Florac
2016-01-26 23:35                                                   ` Seymour, Shane M
2016-01-28 17:31                                                     ` "Kai Mäkisara (Kolumbus)"
2016-01-28 17:39                                                       ` Emmanuel Florac
2016-01-24 21:05                                                 ` Kai Makisara
2016-01-25 10:21                                                   ` Emmanuel Florac
2016-01-28  7:36                                                   ` Seymour, Shane M
2016-01-28 17:04                                                     ` "Kai Mäkisara (Kolumbus)"
2016-01-28 19:21                                                       ` Laurence Oberman
2016-01-28 19:56                                                         ` "Kai Mäkisara (Kolumbus)"
2016-01-28 23:12                                                       ` Seymour, Shane M
2016-01-28 23:23                                                         ` Laurence Oberman
2016-01-28 23:25                                                           ` Laurence Oberman
2016-01-29  0:54                                                             ` Seymour, Shane M
2016-01-29 17:22                                                         ` Kai Makisara
2016-02-01  6:31                                                           ` Seymour, Shane M
2016-02-01 18:43                                                             ` "Kai Mäkisara (Kolumbus)"
2016-02-01 19:02                                                               ` Laurence Oberman
2016-02-01 22:59                                                               ` Seymour, Shane M
2016-02-03  3:40                                                               ` Laurence Oberman
2016-02-03  2:18                                                           ` Seymour, Shane M
2016-02-03 18:36                                                             ` Kai Makisara
2016-02-04  1:43                                                               ` Seymour, Shane M
2016-02-04 17:54                                                                 ` "Kai Mäkisara (Kolumbus)"
2016-02-04 18:09                                                                   ` Douglas Gilbert
2016-02-04 19:25                                                                     ` Laurence Oberman
2016-02-04 18:12                                                                   ` Emmanuel Florac
2016-01-15 11:48                                           ` Emmanuel Florac
2016-01-22 10:17                                           ` Douglas Gilbert
2016-01-06 16:10                               ` Emmanuel Florac
2016-01-06 16:16                                 ` Emmanuel Florac
2016-01-06 16:44                             ` Emmanuel Florac
2015-12-29 16:59           ` Emmanuel Florac
2015-12-29 17:18             ` "Kai Mäkisara (Kolumbus)"
     [not found]   ` <CAAzz28gn2zwC5ZUTtPupDOTHekGspWh0vnWHV+jvbx52c=cq2Q@mail.gmail.com>
2015-12-21 17:49     ` Emmanuel Florac

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=DDB9C85B850785449757F9914A034FCB44517327@G4W3219.americas.hpqcorp.net \
    --to=shane.seymour@hpe.com \
    --cc=eflorac@intellique.com \
    --cc=kai.makisara@kolumbus.fi \
    --cc=linux-scsi@vger.kernel.org \
    --cc=loberman@redhat.com \
    --cc=oberman.l@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.