US20150039933A1 - Storage device and memory accessing method for a storage device - Google Patents
Storage device and memory accessing method for a storage device Download PDFInfo
- Publication number
- US20150039933A1 US20150039933A1 US13/958,602 US201313958602A US2015039933A1 US 20150039933 A1 US20150039933 A1 US 20150039933A1 US 201313958602 A US201313958602 A US 201313958602A US 2015039933 A1 US2015039933 A1 US 2015039933A1
- Authority
- US
- United States
- Prior art keywords
- controller
- memory unit
- host
- storage device
- memory
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/08—Error detection or correction by redundancy in data representation, e.g. by using checking codes
- G06F11/10—Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's
- G06F11/1008—Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's in individual solid state devices
- G06F11/1048—Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's in individual solid state devices using arrangements adapted for a specific error detection or correction feature
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/16—Error detection or correction of the data by redundancy in hardware
- G06F11/1666—Error detection or correction of the data by redundancy in hardware where the redundant component is memory or memory area
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F12/00—Accessing, addressing or allocating within memory systems or architectures
- G06F12/02—Addressing or allocation; Relocation
- G06F12/0223—User address space allocation, e.g. contiguous or non contiguous base addressing
- G06F12/023—Free address space management
- G06F12/0238—Memory management in non-volatile memory, e.g. resistive RAM or ferroelectric memory
- G06F12/0246—Memory management in non-volatile memory, e.g. resistive RAM or ferroelectric memory in block erasable memory, e.g. flash memory
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0602—Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
- G06F3/0604—Improving or facilitating administration, e.g. storage management
- G06F3/0605—Improving or facilitating administration, e.g. storage management by facilitating the interaction with a user or administrator
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0628—Interfaces specially adapted for storage systems making use of a particular technique
- G06F3/0629—Configuration or reconfiguration of storage systems
- G06F3/0634—Configuration or reconfiguration of storage systems by changing the state or mode of one or more devices
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0668—Interfaces specially adapted for storage systems adopting a particular infrastructure
- G06F3/0671—In-line storage system
- G06F3/0673—Single storage device
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2212/00—Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
- G06F2212/72—Details relating to flash memory management
- G06F2212/7211—Wear leveling
Definitions
- the invention relates to a storage device and memory accessing method, and more particularly, to a storage device with connectability to at least two hosts at the same time and memory accessing method for accessing memory units in the storage device by the hosts.
- a portable device may have the capability of transmitting files through wireless connection and also connectable to a computer through a USB connector.
- a number of interfaces may be provided in the portable device for connection with other devices, it is a basic limitation that one channel at a time is workable for the portable device, e.g., for a mobile phone with wireless connection turned on and ready for one host and also with physical connection to another host through USB interface, it can be expected that only one channel, either the wireless connection or the physical connection, will be workable for the mobile phone when both connections are active.
- the controller of a portable device does not take data flow to and from the memory unit of the portable device with the concept of “files” but simply do the reading/writing of the memory unit as commanded. It also lacks of communication and coordination between any built-in OS, such as the linux system, the android system, or the iOS system in the mobile phones, and other OS as in a computer. This is why the rest of the interfaces of a portable device will be shutdown when the portable device is being connected to a computer/host through the USB connector (or through wireless connection).
- any portable device or storage device equipped with more than one way to have connection and data exchange with more than one host should only be able build a data accessing channel with one host at a time, which is quite an inconvenience.
- a third-party application may be developed and installed in one of the hosts that functions as a coordinator among the hosts that are in need of using the channels of the portable device, it takes extra effort to build and install such application in the host, not to mention such application is strongly system dependent.
- a storage device adapted for being connected to and accessible by a first host and a second host.
- the storage device includes a first controller, a second controller, a first memory unit, and a second memory unit.
- the first controller is electrically connected to a first interface that is used to connect to the first host
- the second controller is electrically connected to a second interface that is used to connect to the second host. Both the first memory unit and the second memory unit are connected to and accessible by the first controller and the second controller.
- the first memory unit is readable and writable to the first controller and read-only to the second controller
- the second memory unit is readable and writable to the second controller and read-only to the first controller
- Another embodiment of the storage device also provides that when the storage device is connected to the first host and not connected to the second host, both the first memory unit and the second memory unit are readable and writable to the first controller, and when the storage device is connected to the second host and not connected to the first host, both the first memory unit and the second memory unit are readable and writable to the second controller.
- the storage device also provides that the first interface is a universal serial bus (USB) connector, the second interface is a wireless network channel, and the first memory unit and the second memory unit are non-volatile flash memory.
- USB universal serial bus
- the storage device also provides that the first memory unit includes a first bad block table and the second memory unit includes a second bad block table.
- the first bad block table is updatable to the first controller and read-only to the second controller
- the second bad block table is updatable to the second controller and read-only to the first controller.
- the second controller is adapted for delivering an ECC data of the first memory unit to the first controller
- the first controller is adapted for updating the first bad block table according to the ECC data delivered by the second controller.
- a memory accessing method for a storage device includes a first controller electrically connected to a first interface adapted to be connected to a first host, a second controller electrically connected to a second interface adapted to be connected to a second host, a first memory unit and a second memory unit, both connected to the first controller and the second controller.
- the memory accessing method includes following steps: detecting whether the first interface and the second interface are respectively connected to the first host and the second host; configuring the first memory unit readable and writable to the first controller and read-only to the second controller when the storage device is connected to the first host and the second host at the same time.
- Another embodiment of the memory accessing method also includes the following steps: configuring both the first memory unit and the second memory unit readable and writable to the first controller when the storage device is only connected to the first host and not connected to the second host.
- Another embodiment of the memory accessing method also provides that when the storage device is connected to the first host and the second host at the same time, the memory accessing method further includes the following step: when the second controller is requesting a reading access to the first memory unit, the first controller providing for the second controller reading control to the first memory unit.
- Another embodiment of the memory accessing method also includes the following steps: the first controller updating a first bad block table of the first memory unit; the first controller notifying the second controller an update of the first bad block table; and the second controller reading the first bad block table of the first memory unit.
- Another embodiment of the memory accessing method also includes the following steps: the second controller detecting an ECC error when reading the first memory unit; the second controller notifying the first controller of the ECC error; and the first controller updating a bad block table of the first memory unit according to the ECC error.
- a memory accessing method for a storage device includes a first controller electrically connected to a first interface, a second controller electrically connected to a second interface, and a first memory unit and a second memory unit, both connected to the first controller and the second controller.
- the memory accessing method includes steps: initiating the first controller when the first interface is connected to a first host; detecting whether the second controller is initiated; configuring the first controller to have both read and write authority to both the first memory unit and the second memory unit when the second controller is not initiated; and configuring the first controller to have both read and write authority to the first memory unit and the second controller to have both read and write authority to the second memory unit when the second controller is initiated.
- Another embodiment of the memory accessing method also includes step: configuring the first controller to have only read authority to the second memory unit and the second controller to have only read authority to the first memory unit when the second controller is initiated.
- Another embodiment of the memory accessing method further provides that the step of detecting whether the second controller is initiated is performed by the first controller, and the second controller is initiated when the second interface is connected to a second host.
- Another embodiment of the memory accessing method further provides that the step of the first controller detecting whether the second controller is initiated is performed through a communication channel existed between the first controller and the second controller.
- Another embodiment of the memory accessing method also includes steps: updating a first bad block table of the first memory unit by the first controller; notifying the second controller the update of the first bad block table; and reading the first bad block table of the first memory unit by the second controller.
- Another embodiment of the memory accessing method also includes steps: detecting an ECC error by the second controller when reading the first memory unit; notifying the first controller of the ECC error by the second controller; and updating a bad block table of the first memory unit according to the ECC error by the first controller.
- FIG. 1 shows an illustration of an embodiment of a storage device connected to a first host and a second host.
- FIG. 2A , 2 B are illustrations showing configurations of either the first controller or the second controller being initiated and accessible by only one host.
- FIG. 3 is an illustration showing the configuration of the storage device when both the first interface and the second interface are connected to their corresponding hosts.
- FIG. 4 is an illustration showing a flowchart of an initiating method for the first controller and the second controller.
- FIG. 5 is an illustration of a coordinating method in conflict accessing.
- FIG. 6A is an illustration of a flowchart showing a bad block table synchronizing method initiated by a local controller.
- FIG. 6B is an illustration of a flowchart showing a bad block table synchronizing method initiated by a remote controller.
- FIG. 1 shows an illustration of an embodiment of a storage device connected to a first host and a second host.
- the storage device 30 in discussion in the invention may be a USB flash drive, a portable media player, a mobile phone, or a portable device having mass storage.
- the storage device 30 includes two or more than two interfaces, each can be set to connect, either physically or wirelessly, to a host and data can be transferred between the host and the storage device 30 . Examples are described in the embodiments of the invention in that the storage device has two interfaces; however, for any storage devices that have more than two interfaces, they should be regarded as within the scope of the invention through corresponding and proper modification according to the embodiments described in the invention. In the embodiment in FIG.
- a first host 10 and a second host 20 are connected to the storage device 30 .
- Each of the first host 10 and the second host 20 can be a computer, another storage device, a TV with connectability with other device.
- the built-in OS for example, an embedded Linux, an android system, or an iOS system
- the storage device 30 stored in the ROM may also be placed in the embodiment as either the first host 10 or the second host 20 .
- the storage device 30 includes at least a first controller 31 of a first interface 33 and a second controller 32 of a second interface 34 .
- the first interface 33 is used to connect to the first host 10 and the second interface 34 is used to connect to the second host 20 .
- each of the first interface 33 and the second interface 34 can be set to connect, either physically or wirelessly, to a host.
- the first interface 33 may be a universal serial bus (USB) connector and the second interface 34 may be a wireless network channel, which means the storage device 30 may be connected to the first host 10 via a USB connector and may be connected to the second host 20 wirelessly.
- the first host 10 may also be the built-in OS of the storage device 30 , it can be an integrated component in the storage device 30 that includes the three: the first controller 31 , the first interface 33 , and the first host 10 .
- the storage device 30 also includes a first memory unit 40 and a second memory unit 50 , which preferably are non-volatile flash memories. It should be noted that the first memory unit 40 and the second memory unit 50 may be either physically separated entities or logically separated units. Each of the first memory unit 40 and the second memory unit 50 is an independent memory with dedicated I/O channel, which means the access to the first memory unit 40 is independent from the access to the second memory unit 50 and vice versa, and both the first memory unit 40 and the second memory unit 50 are allowed to be accessed simultaneously, since they have their own I/O channels. Accordingly, it can be shown in FIG. 1 that the first memory unit 40 is accessible through a first I/O channel 41 (denoting “1 st I/O” in FIG.
- the first memory unit 40 also includes a first bad block table 43 (denoting “1 st BBT” in FIG. 1 ) and the second memory unit 50 also includes a second bad block table 53 (denoting “2 nd BBT” in FIG. 1 ).
- the first bad block table 43 and the second bad block table 53 serve as a record of the health status of the memory units whose structure and function should be easily acquirable by any person skilled in the art.
- FIG. 2A , 2 B are illustrations showing configurations of either the first controller or the second controller being initiated and accessible by only one host.
- the first controller 31 has full accessibility of both the first memory unit 40 and the second memory unit 50 , which means both the first memory unit 40 and the second memory unit 50 are accessible by the first controller 31 .
- FIG. 2A when the storage device 30 is connected to and accessible by the first host 10 and not connected to the second host 20 , the first controller 31 has full accessibility of both the first memory unit 40 and the second memory unit 50 , which means both the first memory unit 40 and the second memory unit 50 are accessible by the first controller 31 .
- the second controller 32 when the storage device 30 is connected to and accessible by the second host 20 and not connected to the first host 10 , the second controller 32 also has full accessibility of both the first memory unit 40 and the second memory unit 50 , which means both the first memory unit 40 and the second memory unit 50 are accessible by the second controller 32 .
- FIG. 3 is an illustration showing the configuration of the storage device when both the first interface and the second interface are connected to their corresponding hosts. To prevent causing potential data conflict under the condition that not just one controller has the authority of performing writing to any one memory unit, FIG. 3 and FIG.
- the first memory unit 40 is readable and writable to the first controller 31 and read-only to the second controller 32
- the second memory unit 50 is readable and writable to the second controller 32 and read-only to the first controller 31 .
- both the first host 10 and the second host 20 can still access the storage device 30 but with some accessing restriction to part of the storage.
- the configuration in FIG. 3 allows the storage device 30 to connect to and transfer data to the computer, while writing data to the second memory unit 50 , such as taking photos using the mobile phone and storing the photos in the mobile phone, is still an available function.
- FIG. 4 is an illustration showing a flowchart of an initiating method 100 for the first controller 31 and the second controller 32 .
- the initiating method 100 includes the following steps:
- Step 110 The first controller initiated
- Step 120 Detecting whether the second controller is initiated; if yes, go to step 150 ; if not, go to step 130 ;
- Step 130 The first controller having both read and write authority to both the first memory unit and the second memory unit;
- Step 150 Notifying the second controller to have only read authority to the first memory unit.
- Step 170 The first controller having both read and write authority to the first memory unit and only read authority to the second memory unit; the second controller having both read and write authority to the second memory unit and only read authority to the first memory unit.
- Step 110 the first controller 31 is initiated when the first interface 33 is connected to the first host 10 and once the first controller 31 is initiated and ready to access the first memory unit 40 and the second memory unit 50 , the first controller 31 detects whether the second controller 32 is also initiated when the second interface 34 is connected to the second host 20 as described in Step 120 .
- a communication channel can exist between the first controller 31 and the second controller 32 for the first controller 31 to detect the initiation of the second controller 32 , and vice versa. If the second controller 32 has not been initiated, the storage device 30 turns to the configuration as shown in FIG. 2A and the first controller 31 has both read and write authority to both the first memory unit 40 and the second memory unit 50 as in Step 130 .
- Step 150 the first controller 31 gives a notification to the second controller 32 and the second controller 32 configures itself to have only read authority to the first memory unit 40 as in Step 150 , while the first controller 31 configures itself to have only read authority to the second memory unit 50 .
- the second controller 32 may also actively check on the status of the first memory 40 and configures itself to have only read authority to the first memory 40 when the first memory 40 is being accessed by the first controller 32 .
- Step 170 shows a status of the configuration as shown in FIG. 3 . Please be noted that the initiating method 100 starts with the first controller 31 ; however, the initiating method 100 also applies to a start with the second controller 32 .
- the coordinating method 200 includes the following steps:
- Step 210 The first controller being reading/writing the first memory unit
- Step 230 Request from the second controller for reading the first memory unit
- Step 250 The first controller halting the reading/writing to the first memory unit and answering to the request from the second controller;
- Step 270 The first controller halting the reading of the second controller.
- Step 210 an event of reading the first memory unit 40 by the second controller 32 begins with sending a request from the second controller 32 to the first controller 31 as in Step 230 .
- Step 250 and Step 270 show that the first controller 31 answers to the request and let the second controller 32 read the first memory unit 40 once the first controller 31 halts or finishes the reading/writing to the first memory unit 40 .
- the second controller 32 finishes reading the first memory unit 40
- the first controller 31 halts the reading process to the first memory unit 40 by the second controller 32 .
- the first controller 31 may be notified by the second controller 32 of the finish of reading the first memory unit 40 or the first controller 31 may periodically check up on the status of the first memory unit 40 for ‘knowing’ that the reading from the second controller 32 is finished. It should also be noted that the coordinating method 200 may also start with the second controller 32 .
- FIG. 6A is an illustration of a flowchart showing a bad block table synchronizing method 300 initiated by a local controller
- FIG. 6B is an illustration of a flowchart showing a bad block table synchronizing method 400 initiated by a remote controller.
- the storage device 30 is configured to connect to both hosts as shown in FIG. 3
- the first controller 31 still has full accessibility to the first memory unit 40 and is a local controller to the first memory unit 40
- the second controller 32 is a remote controller to the first memory unit 40 .
- the bad block table synchronizing method 300 includes the following steps:
- Step 310 The first controller updating a first bad block table of the first memory unit
- Step 330 The first controller notifying the second controller the update of the first bad block table
- Step 350 The second controller reading the first bad block table of the first memory unit.
- the bad block table synchronizing method 400 includes the following steps:
- Step 410 The second controller detecting an ECC error when reading the first memory unit
- Step 430 The second controller notifying the first controller of the ECC error.
- Step 450 The first controller updating a bad block table of the first memory unit according to the ECC error.
- bad block table synchronizing method 300 and the bad block table synchronizing method 400 may also start with another controller and carry out the steps in a similar way.
- the storage device and memory accessing method provided in the embodiments of the invention configure two separate memory units, each with dedicated I/O channel, accessible by two controllers, each corresponding to an interface connected to a host, and allows the storage device to establish at least two connections to the different hosts.
- the first controller has both read and write accessibility to the first memory unit and the second controller has both read and write accessibility to the second memory unit, while the first controller has read-only accessibility to the second memory unit and the second controller has read-only accessibility to the second memory unit.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- Quality & Reliability (AREA)
- Techniques For Improving Reliability Of Storages (AREA)
Abstract
Description
- 1. Technical Field
- The invention relates to a storage device and memory accessing method, and more particularly, to a storage device with connectability to at least two hosts at the same time and memory accessing method for accessing memory units in the storage device by the hosts.
- 2. Description of the Conventional Art
- Most portable devices such as USB flash drives, portable media players, mobile phones with built-in storage, etc., are able to connect to more than one device/host through corresponding interface. For example, a portable device may have the capability of transmitting files through wireless connection and also connectable to a computer through a USB connector. Although a number of interfaces may be provided in the portable device for connection with other devices, it is a basic limitation that one channel at a time is workable for the portable device, e.g., for a mobile phone with wireless connection turned on and ready for one host and also with physical connection to another host through USB interface, it can be expected that only one channel, either the wireless connection or the physical connection, will be workable for the mobile phone when both connections are active.
- Generally, the controller of a portable device, say, a mass storage device, does not take data flow to and from the memory unit of the portable device with the concept of “files” but simply do the reading/writing of the memory unit as commanded. It also lacks of communication and coordination between any built-in OS, such as the linux system, the android system, or the iOS system in the mobile phones, and other OS as in a computer. This is why the rest of the interfaces of a portable device will be shutdown when the portable device is being connected to a computer/host through the USB connector (or through wireless connection). Hence, any portable device or storage device equipped with more than one way to have connection and data exchange with more than one host should only be able build a data accessing channel with one host at a time, which is quite an inconvenience.
- Although a third-party application may be developed and installed in one of the hosts that functions as a coordinator among the hosts that are in need of using the channels of the portable device, it takes extra effort to build and install such application in the host, not to mention such application is strongly system dependent.
- According to the embodiments of the invention, a storage device adapted for being connected to and accessible by a first host and a second host is provided. The storage device includes a first controller, a second controller, a first memory unit, and a second memory unit. The first controller is electrically connected to a first interface that is used to connect to the first host, and the second controller is electrically connected to a second interface that is used to connect to the second host. Both the first memory unit and the second memory unit are connected to and accessible by the first controller and the second controller. When the storage device is connected to and accessible by the first host and the second host at the same time, the first memory unit is readable and writable to the first controller and read-only to the second controller, and the second memory unit is readable and writable to the second controller and read-only to the first controller.
- Another embodiment of the storage device also provides that when the storage device is connected to the first host and not connected to the second host, both the first memory unit and the second memory unit are readable and writable to the first controller, and when the storage device is connected to the second host and not connected to the first host, both the first memory unit and the second memory unit are readable and writable to the second controller.
- Another embodiment of the storage device also provides that the first interface is a universal serial bus (USB) connector, the second interface is a wireless network channel, and the first memory unit and the second memory unit are non-volatile flash memory.
- Another embodiment of the storage device also provides that the first memory unit includes a first bad block table and the second memory unit includes a second bad block table. When the storage device is connected to the first host and the second host at the same time, the first bad block table is updatable to the first controller and read-only to the second controller, and the second bad block table is updatable to the second controller and read-only to the first controller. The second controller is adapted for delivering an ECC data of the first memory unit to the first controller, and the first controller is adapted for updating the first bad block table according to the ECC data delivered by the second controller.
- According to the embodiments of the invention, a memory accessing method for a storage device is also provided. The storage device includes a first controller electrically connected to a first interface adapted to be connected to a first host, a second controller electrically connected to a second interface adapted to be connected to a second host, a first memory unit and a second memory unit, both connected to the first controller and the second controller. The memory accessing method includes following steps: detecting whether the first interface and the second interface are respectively connected to the first host and the second host; configuring the first memory unit readable and writable to the first controller and read-only to the second controller when the storage device is connected to the first host and the second host at the same time.
- Another embodiment of the memory accessing method also includes the following steps: configuring both the first memory unit and the second memory unit readable and writable to the first controller when the storage device is only connected to the first host and not connected to the second host.
- Another embodiment of the memory accessing method also provides that when the storage device is connected to the first host and the second host at the same time, the memory accessing method further includes the following step: when the second controller is requesting a reading access to the first memory unit, the first controller providing for the second controller reading control to the first memory unit.
- Another embodiment of the memory accessing method also includes the following steps: the first controller updating a first bad block table of the first memory unit; the first controller notifying the second controller an update of the first bad block table; and the second controller reading the first bad block table of the first memory unit.
- Another embodiment of the memory accessing method also includes the following steps: the second controller detecting an ECC error when reading the first memory unit; the second controller notifying the first controller of the ECC error; and the first controller updating a bad block table of the first memory unit according to the ECC error.
- According to the embodiments of the invention, a memory accessing method for a storage device is also provided. The storage device includes a first controller electrically connected to a first interface, a second controller electrically connected to a second interface, and a first memory unit and a second memory unit, both connected to the first controller and the second controller. The memory accessing method includes steps: initiating the first controller when the first interface is connected to a first host; detecting whether the second controller is initiated; configuring the first controller to have both read and write authority to both the first memory unit and the second memory unit when the second controller is not initiated; and configuring the first controller to have both read and write authority to the first memory unit and the second controller to have both read and write authority to the second memory unit when the second controller is initiated.
- Another embodiment of the memory accessing method also includes step: configuring the first controller to have only read authority to the second memory unit and the second controller to have only read authority to the first memory unit when the second controller is initiated.
- Another embodiment of the memory accessing method further provides that the step of detecting whether the second controller is initiated is performed by the first controller, and the second controller is initiated when the second interface is connected to a second host.
- Another embodiment of the memory accessing method further provides that the step of the first controller detecting whether the second controller is initiated is performed through a communication channel existed between the first controller and the second controller.
- Another embodiment of the memory accessing method also includes steps: updating a first bad block table of the first memory unit by the first controller; notifying the second controller the update of the first bad block table; and reading the first bad block table of the first memory unit by the second controller.
- Another embodiment of the memory accessing method also includes steps: detecting an ECC error by the second controller when reading the first memory unit; notifying the first controller of the ECC error by the second controller; and updating a bad block table of the first memory unit according to the ECC error by the first controller.
- These and other objectives of the present invention will no doubt become obvious to those of ordinary skill in the art after reading the following detailed description of the preferred embodiment that is illustrated in the various figures and drawings.
-
FIG. 1 shows an illustration of an embodiment of a storage device connected to a first host and a second host. -
FIG. 2A , 2B are illustrations showing configurations of either the first controller or the second controller being initiated and accessible by only one host. -
FIG. 3 is an illustration showing the configuration of the storage device when both the first interface and the second interface are connected to their corresponding hosts. -
FIG. 4 is an illustration showing a flowchart of an initiating method for the first controller and the second controller. -
FIG. 5 is an illustration of a coordinating method in conflict accessing. -
FIG. 6A is an illustration of a flowchart showing a bad block table synchronizing method initiated by a local controller. -
FIG. 6B is an illustration of a flowchart showing a bad block table synchronizing method initiated by a remote controller. - Certain terms are used throughout the following description and claims to refer to particular system components. As one skilled in the art will appreciate, manufacturers may refer to a component by different names. In the following discussion and in the claims, the terms “include” and “comprise” are used in an open-ended fashion. Also, the term “couple” is intended to mean either an indirect or direct electrical connection. Thus, if a first device is coupled to a second device, that connection may be through a direct electrical connection, or through an indirect electrical connection via other devices and connections.
- Please refer to
FIG. 1 .FIG. 1 shows an illustration of an embodiment of a storage device connected to a first host and a second host. Thestorage device 30 in discussion in the invention may be a USB flash drive, a portable media player, a mobile phone, or a portable device having mass storage. Thestorage device 30 includes two or more than two interfaces, each can be set to connect, either physically or wirelessly, to a host and data can be transferred between the host and thestorage device 30. Examples are described in the embodiments of the invention in that the storage device has two interfaces; however, for any storage devices that have more than two interfaces, they should be regarded as within the scope of the invention through corresponding and proper modification according to the embodiments described in the invention. In the embodiment inFIG. 1 , afirst host 10 and asecond host 20 are connected to thestorage device 30. Each of thefirst host 10 and thesecond host 20 can be a computer, another storage device, a TV with connectability with other device. In some cases, the built-in OS (for example, an embedded Linux, an android system, or an iOS system) of thestorage device 30 stored in the ROM may also be placed in the embodiment as either thefirst host 10 or thesecond host 20. - According to the way the
storage device 30 builds connections with a number of hosts, thestorage device 30 includes at least afirst controller 31 of afirst interface 33 and asecond controller 32 of asecond interface 34. Thefirst interface 33 is used to connect to thefirst host 10 and thesecond interface 34 is used to connect to thesecond host 20. As mentioned, each of thefirst interface 33 and thesecond interface 34 can be set to connect, either physically or wirelessly, to a host. Hence, to describe the structure of the embodiment in an exemplary way, for example, thefirst interface 33 may be a universal serial bus (USB) connector and thesecond interface 34 may be a wireless network channel, which means thestorage device 30 may be connected to thefirst host 10 via a USB connector and may be connected to thesecond host 20 wirelessly. As for the case that thefirst host 10 may also be the built-in OS of thestorage device 30, it can be an integrated component in thestorage device 30 that includes the three: thefirst controller 31, thefirst interface 33, and thefirst host 10. - The
storage device 30 also includes afirst memory unit 40 and asecond memory unit 50, which preferably are non-volatile flash memories. It should be noted that thefirst memory unit 40 and thesecond memory unit 50 may be either physically separated entities or logically separated units. Each of thefirst memory unit 40 and thesecond memory unit 50 is an independent memory with dedicated I/O channel, which means the access to thefirst memory unit 40 is independent from the access to thesecond memory unit 50 and vice versa, and both thefirst memory unit 40 and thesecond memory unit 50 are allowed to be accessed simultaneously, since they have their own I/O channels. Accordingly, it can be shown inFIG. 1 that thefirst memory unit 40 is accessible through a first I/O channel 41 (denoting “1st I/O” inFIG. 1 ) and connected to both thefirst controller 31 and thesecond controller 32, and likewise, thesecond memory unit 50 is accessible through a second I/O channel 51 (denoting “2nd I/O” inFIG. 1 ) and connected to both thefirst controller 31 and thesecond controller 32. Also shown inFIG. 1 , thefirst memory unit 40 also includes a first bad block table 43 (denoting “1st BBT” inFIG. 1 ) and thesecond memory unit 50 also includes a second bad block table 53 (denoting “2nd BBT” inFIG. 1 ). The first bad block table 43 and the second bad block table 53 serve as a record of the health status of the memory units whose structure and function should be easily acquirable by any person skilled in the art. - Please refer to
FIG. 2A , 2B.FIG. 2A , 2B are illustrations showing configurations of either the first controller or the second controller being initiated and accessible by only one host. As shown inFIG. 2A , when thestorage device 30 is connected to and accessible by thefirst host 10 and not connected to thesecond host 20, thefirst controller 31 has full accessibility of both thefirst memory unit 40 and thesecond memory unit 50, which means both thefirst memory unit 40 and thesecond memory unit 50 are accessible by thefirst controller 31. InFIG. 2B , when thestorage device 30 is connected to and accessible by thesecond host 20 and not connected to thefirst host 10, thesecond controller 32 also has full accessibility of both thefirst memory unit 40 and thesecond memory unit 50, which means both thefirst memory unit 40 and thesecond memory unit 50 are accessible by thesecond controller 32. - Please refer to
FIG. 3 .FIG. 3 is an illustration showing the configuration of the storage device when both the first interface and the second interface are connected to their corresponding hosts. To prevent causing potential data conflict under the condition that not just one controller has the authority of performing writing to any one memory unit,FIG. 3 andFIG. 1 show that when thestorage device 30 is connected to and accessible by thefirst host 10 and thesecond host 20 at the same time, one of thememory units first memory unit 40 is readable and writable to thefirst controller 31 and read-only to thesecond controller 32, and thesecond memory unit 50 is readable and writable to thesecond controller 32 and read-only to thefirst controller 31. As such, both thefirst host 10 and thesecond host 20 can still access thestorage device 30 but with some accessing restriction to part of the storage. - For example, when the
first host 10 is a computer connected to thestorage device 30, a mobile phone, via thefirst interface 33, an USB connector, and thesecond host 20 as the built-in OS of thestorage device 30, the configuration inFIG. 3 allows thestorage device 30 to connect to and transfer data to the computer, while writing data to thesecond memory unit 50, such as taking photos using the mobile phone and storing the photos in the mobile phone, is still an available function. - To make the
storage device 30 as described implementable, a memory accessing method for thestorage device 30 is also provided in another preferred embodiment of the invention. The memory accessing method includes a number of steps as shown inFIG. 4 , 5, 6A, 6B. Please refer toFIG. 4 first, which is an illustration showing a flowchart of an initiatingmethod 100 for thefirst controller 31 and thesecond controller 32. The initiatingmethod 100 includes the following steps: - Step 110: The first controller initiated;
- Step 120: Detecting whether the second controller is initiated; if yes, go to step 150; if not, go to step 130;
- Step 130: The first controller having both read and write authority to both the first memory unit and the second memory unit;
- Step 150: Notifying the second controller to have only read authority to the first memory unit; and
- Step 170: The first controller having both read and write authority to the first memory unit and only read authority to the second memory unit; the second controller having both read and write authority to the second memory unit and only read authority to the first memory unit.
- In
Step 110, thefirst controller 31 is initiated when thefirst interface 33 is connected to thefirst host 10 and once thefirst controller 31 is initiated and ready to access thefirst memory unit 40 and thesecond memory unit 50, thefirst controller 31 detects whether thesecond controller 32 is also initiated when thesecond interface 34 is connected to thesecond host 20 as described inStep 120. In thestorage device 30, a communication channel can exist between thefirst controller 31 and thesecond controller 32 for thefirst controller 31 to detect the initiation of thesecond controller 32, and vice versa. If thesecond controller 32 has not been initiated, thestorage device 30 turns to the configuration as shown inFIG. 2A and thefirst controller 31 has both read and write authority to both thefirst memory unit 40 and thesecond memory unit 50 as inStep 130. If thesecond controller 32 is detected to be initiated, thefirst controller 31 gives a notification to thesecond controller 32 and thesecond controller 32 configures itself to have only read authority to thefirst memory unit 40 as inStep 150, while thefirst controller 31 configures itself to have only read authority to thesecond memory unit 50. Thesecond controller 32 may also actively check on the status of thefirst memory 40 and configures itself to have only read authority to thefirst memory 40 when thefirst memory 40 is being accessed by thefirst controller 32. And Step 170 shows a status of the configuration as shown inFIG. 3 . Please be noted that the initiatingmethod 100 starts with thefirst controller 31; however, the initiatingmethod 100 also applies to a start with thesecond controller 32. - Please refer to
FIG. 5 for an illustration of acoordinating method 200 in conflict accessing afterStep 170 is performed. The coordinatingmethod 200 includes the following steps: - Step 210: The first controller being reading/writing the first memory unit;
- Step 230: Request from the second controller for reading the first memory unit;
- Step 250: The first controller halting the reading/writing to the first memory unit and answering to the request from the second controller;
- Step 270: The first controller halting the reading of the second controller.
- When the
first controller 31 is reading or writing thefirst memory unit 40 as inStep 210, an event of reading thefirst memory unit 40 by thesecond controller 32 begins with sending a request from thesecond controller 32 to thefirst controller 31 as inStep 230. Step 250 andStep 270 show that thefirst controller 31 answers to the request and let thesecond controller 32 read thefirst memory unit 40 once thefirst controller 31 halts or finishes the reading/writing to thefirst memory unit 40. When thesecond controller 32 finishes reading thefirst memory unit 40, thefirst controller 31 halts the reading process to thefirst memory unit 40 by thesecond controller 32. Thefirst controller 31 may be notified by thesecond controller 32 of the finish of reading thefirst memory unit 40 or thefirst controller 31 may periodically check up on the status of thefirst memory unit 40 for ‘knowing’ that the reading from thesecond controller 32 is finished. It should also be noted that the coordinatingmethod 200 may also start with thesecond controller 32. - Please refer to
FIG. 6A , 6B.FIG. 6A is an illustration of a flowchart showing a bad blocktable synchronizing method 300 initiated by a local controller andFIG. 6B is an illustration of a flowchart showing a bad blocktable synchronizing method 400 initiated by a remote controller. When thestorage device 30 is configured to connect to both hosts as shown inFIG. 3 , thefirst controller 31 still has full accessibility to thefirst memory unit 40 and is a local controller to thefirst memory unit 40, whereas thesecond controller 32 is a remote controller to thefirst memory unit 40. The same naming applies to the two controllers in a similar way regarding thesecond memory unit 40. InFIG. 6A , the bad blocktable synchronizing method 300 includes the following steps: - Step 310: The first controller updating a first bad block table of the first memory unit;
- Step 330: The first controller notifying the second controller the update of the first bad block table; and
- Step 350: The second controller reading the first bad block table of the first memory unit.
- In
FIG. 6B , the bad blocktable synchronizing method 400 includes the following steps: - Step 410: The second controller detecting an ECC error when reading the first memory unit;
- Step 430: The second controller notifying the first controller of the ECC error; and
- Step 450: The first controller updating a bad block table of the first memory unit according to the ECC error.
- Also please be noted that the bad block
table synchronizing method 300 and the bad blocktable synchronizing method 400 may also start with another controller and carry out the steps in a similar way. - The storage device and memory accessing method provided in the embodiments of the invention configure two separate memory units, each with dedicated I/O channel, accessible by two controllers, each corresponding to an interface connected to a host, and allows the storage device to establish at least two connections to the different hosts. As more than one connection is established between the storage device and the hosts at the same time, the first controller has both read and write accessibility to the first memory unit and the second controller has both read and write accessibility to the second memory unit, while the first controller has read-only accessibility to the second memory unit and the second controller has read-only accessibility to the second memory unit.
- Those skilled in the art will readily observe that numerous modifications and alterations of the device and method may be made while retaining the teachings of the invention. Accordingly, the above disclosure should be construed as limited only by the metes and bounds of the appended claims.
Claims (20)
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US13/958,602 US8966137B1 (en) | 2013-08-04 | 2013-08-04 | Storage device and memory accessing method for a storage device |
TW103126520A TWI501142B (en) | 2013-08-04 | 2014-08-01 | Storage device and memory accessing method for a storage device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US13/958,602 US8966137B1 (en) | 2013-08-04 | 2013-08-04 | Storage device and memory accessing method for a storage device |
Publications (2)
Publication Number | Publication Date |
---|---|
US20150039933A1 true US20150039933A1 (en) | 2015-02-05 |
US8966137B1 US8966137B1 (en) | 2015-02-24 |
Family
ID=52428808
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US13/958,602 Active US8966137B1 (en) | 2013-08-04 | 2013-08-04 | Storage device and memory accessing method for a storage device |
Country Status (2)
Country | Link |
---|---|
US (1) | US8966137B1 (en) |
TW (1) | TWI501142B (en) |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150363341A1 (en) * | 2014-06-15 | 2015-12-17 | Transcend Information, Inc. | External storage device |
US20160364178A1 (en) * | 2015-06-12 | 2016-12-15 | Nintendo Co., Ltd. | Information processing apparatus, information processing system, storage medium and information processing method |
US20170371576A1 (en) * | 2016-06-22 | 2017-12-28 | EMC IP Holding Company LLC | Method and system for delivering message in storage system |
CN107526537A (en) * | 2016-06-22 | 2017-12-29 | 伊姆西公司 | For locking the method and system of the storage region in storage system |
US20180137072A1 (en) * | 2016-11-16 | 2018-05-17 | POWER 7 TECHNOLOGY CORP. (Shenzhen) | Intelligent storage device signal transmission method |
US20190138229A1 (en) * | 2017-11-08 | 2019-05-09 | SK Hynix Inc. | Memory device and memory system including the same |
US20200097171A1 (en) * | 2018-09-21 | 2020-03-26 | Samsung Electronics Co., Ltd. | Storage device |
US12124709B2 (en) * | 2022-08-31 | 2024-10-22 | Alibaba (China) Co., Ltd. | Computing system and associated method |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2013028854A1 (en) * | 2011-08-24 | 2013-02-28 | Rambus Inc. | Methods and systems for mapping a peripheral function onto a legacy memory interface |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20140012940A1 (en) * | 2012-07-03 | 2014-01-09 | Fusion-Io, Inc. | Systems, Methods and Apparatus for a Virtual Machine Cache |
US20140032515A1 (en) * | 2010-05-20 | 2014-01-30 | Vmware, Inc. | File system with optimistic i/o operations on shared storage |
Family Cites Families (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7676640B2 (en) * | 2000-01-06 | 2010-03-09 | Super Talent Electronics, Inc. | Flash memory controller controlling various flash memory cells |
TWI269176B (en) * | 2004-02-13 | 2006-12-21 | Ene Technology Inc | Access device with a multi-channel transmission |
US8010740B2 (en) * | 2006-06-08 | 2011-08-30 | Bitmicro Networks, Inc. | Optimizing memory operations in an electronic storage device |
TW200926195A (en) * | 2007-12-06 | 2009-06-16 | Apacer Technology Inc | Multi-interface storgae device for using in computer of power off status |
TWM365529U (en) * | 2009-04-03 | 2009-09-21 | Genesys Logic Inc | Data access apparatus and processing system using the same |
TWI454922B (en) * | 2011-12-19 | 2014-10-01 | Phison Electronics Corp | Memory storage device and memory controller and data writing method thereof |
-
2013
- 2013-08-04 US US13/958,602 patent/US8966137B1/en active Active
-
2014
- 2014-08-01 TW TW103126520A patent/TWI501142B/en active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20140032515A1 (en) * | 2010-05-20 | 2014-01-30 | Vmware, Inc. | File system with optimistic i/o operations on shared storage |
US20140012940A1 (en) * | 2012-07-03 | 2014-01-09 | Fusion-Io, Inc. | Systems, Methods and Apparatus for a Virtual Machine Cache |
Cited By (16)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US9606943B2 (en) * | 2014-06-15 | 2017-03-28 | Transcend Information, Inc. | External storage device with two interfaces |
US20150363341A1 (en) * | 2014-06-15 | 2015-12-17 | Transcend Information, Inc. | External storage device |
US20160364178A1 (en) * | 2015-06-12 | 2016-12-15 | Nintendo Co., Ltd. | Information processing apparatus, information processing system, storage medium and information processing method |
US20200174683A1 (en) * | 2016-06-22 | 2020-06-04 | EMC IP Holding Company LLC | Method and system for delivering message in storage system |
US20170371576A1 (en) * | 2016-06-22 | 2017-12-28 | EMC IP Holding Company LLC | Method and system for delivering message in storage system |
CN107526537A (en) * | 2016-06-22 | 2017-12-29 | 伊姆西公司 | For locking the method and system of the storage region in storage system |
CN107526538A (en) * | 2016-06-22 | 2017-12-29 | 伊姆西公司 | For transmitting the method and system of message within the storage system |
US10552067B2 (en) * | 2016-06-22 | 2020-02-04 | EMC IP Holding Company, LLC | Method and system for delivering message in storage system |
US10860224B2 (en) * | 2016-06-22 | 2020-12-08 | EMC IP Holding Company, LLC | Method and system for delivering message in storage system |
US20180137072A1 (en) * | 2016-11-16 | 2018-05-17 | POWER 7 TECHNOLOGY CORP. (Shenzhen) | Intelligent storage device signal transmission method |
US10248598B2 (en) * | 2016-11-16 | 2019-04-02 | POWER 7 TECHNOLOGY CORP. (Shenzhen) | Intelligent storage device signal transmission method for backing up data on intelligent storage module based on system type of electronic device |
US20190138229A1 (en) * | 2017-11-08 | 2019-05-09 | SK Hynix Inc. | Memory device and memory system including the same |
US10761747B2 (en) * | 2017-11-08 | 2020-09-01 | SK Hynix Inc. | Memory device and memory system including the same |
US20200097171A1 (en) * | 2018-09-21 | 2020-03-26 | Samsung Electronics Co., Ltd. | Storage device |
US11762558B2 (en) * | 2018-09-21 | 2023-09-19 | Samsung Electronics Co., Ltd. | Storage device having a controller that communicates with each of two memories through separate interfaces |
US12124709B2 (en) * | 2022-08-31 | 2024-10-22 | Alibaba (China) Co., Ltd. | Computing system and associated method |
Also Published As
Publication number | Publication date |
---|---|
US8966137B1 (en) | 2015-02-24 |
TW201506772A (en) | 2015-02-16 |
TWI501142B (en) | 2015-09-21 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8966137B1 (en) | Storage device and memory accessing method for a storage device | |
US8316160B2 (en) | Non-volatile memory device with USB and wireless connectivity and method for controlling the connectivity | |
US9722376B2 (en) | Connecting device and method for recognizing device | |
US10754811B2 (en) | Multi-mode NVMe over fabrics devices | |
US8626932B2 (en) | Device-dependent selection between modes for asymmetric serial protocols | |
US20140013067A1 (en) | Control method of storage apparatus | |
TWI677214B (en) | Docking device, electrical device, and mac address cloning method | |
US20150381769A1 (en) | Server, server management system and server management method | |
US8769628B2 (en) | Remote access to a data storage device | |
US20140208006A1 (en) | Apparatus and method for extending memory in terminal | |
US20130040702A1 (en) | Sd switch box in a cellular handset | |
US20100325326A1 (en) | Device information management system and device information management method | |
KR101821016B1 (en) | Apparatus, system and method for allocating identifiers to components of a control system | |
US8509738B2 (en) | Secure device identification protocol with autonomous determination of specific class and capabilities of an electronic device cradle connected to an electronic device | |
US20190056929A1 (en) | Data transmission method and communication system | |
US9207713B1 (en) | Location-based device docking | |
US9116797B2 (en) | Flash memory devices including reserve units operating in abnormal situations and controlling methods thereof | |
US10496153B2 (en) | Method and system for binding chassis and components | |
US11983138B2 (en) | Self-configuring SSD multi-protocol support in host-less environment | |
KR101371885B1 (en) | Compound usb device and method of accessing network service using the same | |
US20200192836A1 (en) | Multiple-path thunderbolt storage apparatus and system | |
US20130262729A1 (en) | System and method for file sharing | |
US20190229766A1 (en) | Elimination of crosstalk effects in non-volatile storage | |
US20140052909A1 (en) | Control system and method for storage configuration | |
CN104252318A (en) | Data storing and processing method, device and terminal |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
AS | Assignment |
Owner name: TRANSCEND INFORMATION, INC., TAIWAN Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNOR:CHEN, REN-WEI;REEL/FRAME:030938/0231 Effective date: 20130603 |
|
STCF | Information on status: patent grant |
Free format text: PATENTED CASE |
|
MAFP | Maintenance fee payment |
Free format text: PAYMENT OF MAINTENANCE FEE, 4TH YEAR, LARGE ENTITY (ORIGINAL EVENT CODE: M1551) Year of fee payment: 4 |
|
MAFP | Maintenance fee payment |
Free format text: PAYMENT OF MAINTENANCE FEE, 8TH YEAR, LARGE ENTITY (ORIGINAL EVENT CODE: M1552); ENTITY STATUS OF PATENT OWNER: LARGE ENTITY Year of fee payment: 8 |