Linux support for S70GL02GS

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hi,

I am looking for the Linux patch to support the S70GL02GS Flash.  According to this KB article (S70GL02GS Support Under Linux - KBA218976 ), you have to create a Support Case to receive the patch.  I have done so, but I have only received automated replies so far.

I am also interested in how to specify the S70GL02GS in the Device Tree Source (.dts) file that Linux parses when it is loaded.  For a typical CFI-compatible 2Mbit, 128Mx16 NOR Flash, I would expect its entry to look something like this:

  norflash@0,0 {

   #address-cells = <0x1>;

   #size-cells = <0x1>;

   compatible = "cfi-flash";

   reg = <0x0 0x0 0x10000000>;

   bank-width = <0x2>;

   device-width = <0x1>;

But the S70GL02GS is actually two 1Mbit NOR Flash die (S29GL01GS) in the same package.  So there is one external chip select, but internally there are two address-mapped regions that have independent protected sectors and control/status registers.  Perhaps there would be two "reg" declarations to account for the two sets of control registers, one at byte offset 0x8000000?

0 Likes
1 Solution

Hello Mike,

A special attention must be given when handling the dual-die S70GL02GS device. The reason for this is that the commands must be addressed to every die separately (specially the unlock commands: 0x555/0xaa & 0x2AA/0x55) otherwise the commands may not work.

That's why this chip needs to be treated as two separate devices although they're sitting under the same CS#.

So probing the device should be done in two steps, that's why the need for two device entries in the device tree.

These two devices will be located in two consecutive mapped addresses and you will have to run your probing function on these two mapped addresses, of 1Gb each.

You can then chose to use the mtd-concat feature to concatenate your two mtd devices and make them look like one.

Unfortunately, I don't have any linux based example for this chip.

I hope it's clear enough now. Thanks!

Best regards,

Bacem

----

Bacem Daassi

Cypress Semiconductor Corp.

Customer Application Engineering

View solution in original post

4 Replies