Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 25 Apr 2014 14:09:17 -0500
From:      Wes Morgan <morganw@chemikals.org>
To:        Hans Petter Selasky <hps@selasky.org>
Cc:        freebsd-usb@freebsd.org
Subject:   Re: LBA Error on 128GB Flash Drive
Message-ID:  <CALCz5ME7hJd4HZgz4wV5OD4XudP6sCPRBoz5oA6_QSSXu27L6w@mail.gmail.com>
In-Reply-To: <5353CF78.1080406@selasky.org>
References:  <CALCz5MHdpxmkBE23-Vj%2BZLfzTaZZT6FpKW7jJT_NZbiqDQ%2BBzg@mail.gmail.com> <5353CF78.1080406@selasky.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Apr 20, 2014 at 8:45 AM, Hans Petter Selasky <hps@selasky.org>wrote:

> On 04/20/14 12:54, Wes Morgan wrote:
>
>> I've got an ADATA 128gb USB3 flash drive (
>> http://www.newegg.com/Product/Product.aspx?Item=N82E16820211819) that is
>> giving me LBA errors. It appears that the drive is being mis-identified
>> and
>> reporting the wrong number of sectors. Camcontrol says the last block
>> is 246960127, which I believe to be correct because any attempt to write
>> to
>> a block after that fails. However, the kernel thinks that the device
>> has 247484416 sectors and pretty much everything fails to use the device
>> properly because partition tables and filesystems like to store things at
>> the end of devices. This is the second one of these I've had and both have
>> the same error. My laptop is fairly old and USB2 only, but I've got some
>> newer machines with USB3 ports and they have the same problem. Attaching
>> the drive to a Linux machine reports the correct number of blocks.
>>
>> All my FreeBSD machines are running 10-stable.
>>
>> Camcontrol output:
>> [morganw@mercury:~$]: camcontrol readcap da0
>> Last Block: 246960127, Block Length: 512 bytes
>>
>
> Does the device have a bad disk label ?
>
> gpart show da0
>
> vs
>
> diskinfo da0
>
>
> --HPS
>
>

Turns out this device reports the wrong capacity with RC16 and needs a cam
quirk to disable it. I'll submit a PR.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CALCz5ME7hJd4HZgz4wV5OD4XudP6sCPRBoz5oA6_QSSXu27L6w>