* Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534)
@ 2016-05-15 20:19 Carina Willbold
2016-05-15 23:48 ` Carina Willbold
0 siblings, 1 reply; 5+ messages in thread
From: Carina Willbold @ 2016-05-15 20:19 UTC (permalink / raw)
Dear NVMe hackers,
I'm trying to access the built-in flash drive of the new April 2016
MacBook 12" (A1534). Based on suggestions for older MacBooks on this
list, I loaded the module nvme, and, since the flash drive reports an
incorrect PCI device class, manually bound it with:
echo 106b 2003 > /sys/bus/pci/drivers/nvme/new_id
The dmesg output is non-informative, it just reports that the probe
failed. The flash drive reports under lspci -nn as:
01:00.0 Mass storage controller [0180]: Apple Inc. Device
[106b:2003] (rev 11)
Note that this is different from previous versions of the MacBook
(where the PCI ID was 106b:2001). The flash drive is detected from the
Grub shell and works just fine from Mac OS X.
I know a bit of C, but have zero experience debugging or programming
drivers. I'm willing to learn! What should I try next?
Thank you for any advice :-).
LLAP
Carina
PS: I also posted this at
http://unix.stackexchange.com/questions/283154/accessing-the-nvme-flash-drive-of-the-april-2016-macbook-12-a1534.
However I believe that this list is better suited.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534)
2016-05-15 20:19 Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534) Carina Willbold
@ 2016-05-15 23:48 ` Carina Willbold
2016-05-16 2:59 ` Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534) [SOLVED] Carina Willbold
0 siblings, 1 reply; 5+ messages in thread
From: Carina Willbold @ 2016-05-15 23:48 UTC (permalink / raw)
Dear NVMe hackers,
Am 2016-05-15 22:19, schrieb Carina Willbold:
> I'm trying to access the built-in flash drive of the new April 2016
> MacBook 12" (A1534).
please forgive me for commiting a basic newbie mistake: I went with the
default Arch Linux kernel (4.5.1) instead of going for the newest one.
I'm sorry for the noise.
With 4.6.0-rc7, after binding using
echo 106b 2003 > /sys/bus/pci/drivers/nvme/new_id
the flash disk *is* recognized:
[ 126.904767] nvme nvme0: pci function 0000:01:00.0
[ 127.117492] nvme0n1: p1 p2 p3 p4
However actually trying to access one of the partitions (for instance,
trying
to mount them or executing head -c 20 /dev/nvme0n1p1) results in
timeouts:
[ 187.354937] nvme nvme0: I/O 0 QID 0 timeout, reset controller
[ 187.365069] nvme nvme0: I/O 0 QID 1 timeout, aborting
[ 200.322625] nvme nvme0: completing aborted command with status:
0000
[ 200.322634] nvme nvme0: completing aborted command with status:
0000
[ 269.366379] nvme nvme0: I/O 1 QID 1 timeout, reset controller
[ 308.027258] nvme nvme0: completing aborted command with status:
0000
[ 308.027295] nvme nvme0: completing aborted command with status:
0000
[ 308.027314] nvme nvme0: completing aborted command with status:
0000
At one point printing the first few bytes of /dev/nvme0n1p1 actually
succeeded
(giving the expected EFI/FAT32 headers).
I'm happy to provide any additional information or start hacking the
driver code
(if given a starting point).
LLAP,
Carina
^ permalink raw reply [flat|nested] 5+ messages in thread
* Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534) [SOLVED]
2016-05-15 23:48 ` Carina Willbold
@ 2016-05-16 2:59 ` Carina Willbold
2016-05-16 14:46 ` Keith Busch
0 siblings, 1 reply; 5+ messages in thread
From: Carina Willbold @ 2016-05-16 2:59 UTC (permalink / raw)
Dear NVMe hackers,
I promise that this is the last time I'll spam this list.
Am 2016-05-16 01:48, schrieb Carina Willbold:
> Am 2016-05-15 22:19, schrieb Carina Willbold:
>> I'm trying to access the built-in flash drive of the new April 2016
>> MacBook 12" (A1534).
[...]
> However actually trying to access one of the partitions (for
> instance, trying
> to mount them or executing head -c 20 /dev/nvme0n1p1) results in
> timeouts:
[...]
After a reboot, the timeouts vanished.
I can now happily confirm that accessing the flash drive works using
kernel 4.6.0-rc7 and manually binding using:
echo 106b 2003 > /sys/bus/pci/drivers/nvme/new_id
No controller resets or other IO errors occur even with (moderately)
drive-intense activities like compiling and installing packages.
I'll submit a patch which will make the manual binding superfluous
tomorrow.
LLAP,
Carina
^ permalink raw reply [flat|nested] 5+ messages in thread
* Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534) [SOLVED]
2016-05-16 2:59 ` Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534) [SOLVED] Carina Willbold
@ 2016-05-16 14:46 ` Keith Busch
2016-05-16 17:55 ` Carina Willbold
0 siblings, 1 reply; 5+ messages in thread
From: Keith Busch @ 2016-05-16 14:46 UTC (permalink / raw)
On Mon, May 16, 2016@04:59:51AM +0200, Carina Willbold wrote:
> >Am 2016-05-15 22:19, schrieb Carina Willbold:
> >However actually trying to access one of the partitions (for instance,
> >trying
> >to mount them or executing head -c 20 /dev/nvme0n1p1) results in timeouts:
> [...]
>
> After a reboot, the timeouts vanished.
>
> I can now happily confirm that accessing the flash drive works using kernel
> 4.6.0-rc7 and manually binding using:
>
> echo 106b 2003 > /sys/bus/pci/drivers/nvme/new_id
>
> No controller resets or other IO errors occur even with (moderately)
> drive-intense activities like compiling and installing packages.
>
> I'll submit a patch which will make the manual binding superfluous tomorrow.
It was starting to sound like you might need to copy the current Apple
driver quirk for the 0x2001 device, but if it's working without, you
can just append the VID/DID to nvme's pci_device_id table.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534) [SOLVED]
2016-05-16 14:46 ` Keith Busch
@ 2016-05-16 17:55 ` Carina Willbold
0 siblings, 0 replies; 5+ messages in thread
From: Carina Willbold @ 2016-05-16 17:55 UTC (permalink / raw)
Dear Keith,
Am 2016-05-16 16:46, schrieb Keith Busch:
> On Mon, May 16, 2016@04:59:51AM +0200, Carina Willbold wrote:
[ Trying to get the flash disk on the new MacBook recognized ]
>> I can now happily confirm that accessing the flash drive works using
>> kernel
>> 4.6.0-rc7 and manually binding using:
>>
>> echo 106b 2003 > /sys/bus/pci/drivers/nvme/new_id
>>
>> No controller resets or other IO errors occur even with (moderately)
>> drive-intense activities like compiling and installing packages.
>>
>> I'll submit a patch which will make the manual binding superfluous
>> tomorrow.
>
> It was starting to sound like you might need to copy the current
> Apple
> driver quirk for the 0x2001 device, but if it's working without, you
> can just append the VID/DID to nvme's pci_device_id table.
yes, thought so too, but it's working without. I can confirm that the
flash drive works fine and is automatically detected with the (trivial)
patch given in the other mail. The patch is against 4.6, but it applies
cleanly against the current linux-next and axboe/linux-block.
In my boot scripts, I had to include a short sleep because I was too
lazy to properly wait for the device files to come into existence.
Thank you for your answer!
LLAP,
Carina
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2016-05-16 17:55 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-15 20:19 Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534) Carina Willbold
2016-05-15 23:48 ` Carina Willbold
2016-05-16 2:59 ` Accessing the NVMe flash drive of the April 2016 MacBook 12" (A1534) [SOLVED] Carina Willbold
2016-05-16 14:46 ` Keith Busch
2016-05-16 17:55 ` Carina Willbold
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.