System and method for controlling multiple devices via general purpose input/output (GPIO) hardware
AssigneeSun Microsystems, Inc.
InventorRichard A. Zatorski
Life of this patent
Estimating the term…
Abstract
A computer system including a storage device, a first and second device driver, and a nexus driver. The storage device has multiple bit positions, and is coupled to a set of electrical terminals. A first portion of the electrical terminals is adapted for coupling to a first device, and a second portion of the electrical terminals is adapted for coupling to a second device. Each device driver controls a respective device by generating an access to the storage device, and writing a value to a respective portion of the bit positions. The nexus device driver is coupled between the first and second device drivers and the storage device, and arbitrates between the first and second device drivers for access to the storage device.
Claims27
A computer system, comprising
- a storage device comprising a plurality of bit positions and operably coupled to a plurality of electrical terminals, wherein a first portion of the electrical terminals is adapted for coupling to a first device, and wherein a second portion of the electrical terminals is adapted for coupling to a second device;
- a first device driver configured to control the first device by accessing the storage device and writing a value to a first portion of the bit positions;
- a second device driver configured to control the second device by accessing the storage device and writing a value to a second portion of the bit positions;
- and
- a nexus device driver operably coupled between the first and second device drivers and the storage device, and configured to grant exclusive access to the storage device to either the first or the second device driver;
- wherein said granting exclusive access comprises:
- detecting that a given device driver is attempting to modify one or more of the bit positions;
- determining which of the bit positions the given device driver owns;
- preventing the given device driver from modifying any of the bit positions of the storage device if one or more of the bit positions that the given device driver is attempting to modify is not owned by the given device driver;
- granting the given device driver access to the storage device if all of the bit positions the given device driver is attempting to modify are owned by the given device driver;
- preventing the second device driver from writing a value to the second portion of the bit positions if the first device driver is granted access to the storage device;
- and
- preventing the first device driver from writing a value to the first portion of the bit positions if the second device driver is granted access to the storage device.
A computer system, comprising:
- a bus bridge circuit, comprising:
- a plurality of electrical terminals including a first portion and a second portion;
- and
- a storage device operably coupled to the electrical terminals and having a plurality of bit positions;
- a first device coupled to the first portion of the electrical terminals;
- a second device coupled to the second portion of the electrical terminals;
- wherein the bus bridge circuit is configurable to generate a first set of signals for controlling the first device dependent upon values stored in a first portion of the bit positions, and to drive the first set of signals upon the first portion of the electrical terminals;
- wherein the bus bridge circuit is configurable to generate a second set of signals for controlling the second device dependent upon values stored in a second portion of the bit positions, and to drive the second set of signals upon the second portion of electrical terminals;
- a first device driver for controlling the first device by accessing the storage device and writing a value to the first portion of the bit positions;
- a second device driver for controlling the second device by accessing the storage device and writing a value to the second portion of the bit positions;
- and
- a nexus device driver operably coupled between the first and second device drivers and the storage device, and configured to grant exclusive access to the storage device to either the first or the second device driver;
- wherein said granting exclusive access comprises:
- detecting that a given device driver is attempting to modify one or more of the bit positions;
- determining which of the bit positions the given device driver owns;
- preventing the given device driver from modifying any of the bit positions of the storage device if one or more of the bit positions that the given device driver is attempting to modify is not owned by the given device driver;
- granting the given device driver access to the storage device if all of the bit positions the given device driver is attempting to modify are owned by the given device driver;
- preventing the second device driver from writing a value to the second portion of the bit positions if the first device driver is granted access to the storage device;
- and
- preventing the first device driver from writing a value to the first portion of the bit positions if the second device driver is granted access to the storage device.
A method for controlling access to a plurality of devices through a shared storage device, wherein the storage device comprises a plurality of bit positions coupled to a plurality of electrical terminals, wherein values stored in the bit positions are used to control the operations of the plurality of devices, wherein a first portion of the electrical terminals is coupled to a first device, and wherein a second portion of the electrical terminals is coupled to a second device, the method comprising:
- initiating a first access to the storage device, wherein the first access is initiated by a first device driver and is configured to write a value to a first portion of the bit positions;
- initiating a second access to the storage device, wherein the second access is initiated by a second device driver and is configured to write a value to a second portion of the bit positions;
- and
- a nexus device driver granting exclusive access to the storage device to either the first or the second device driver;
- wherein said granting exclusive access comprises:
- detecting that a given device driver is attempting to modify one or more of the bit positions;
- determining which of the bit positions the given device driver owns;
- preventing the given device driver from modifying any of the bit positions of the storage device if one or more of the bit positions that the given device driver is attempting to modify is not owned by the given device driver;
- granting the given device driver access to the storage device if all of the bit positions the given device driver is attempting to modify are owned by the given device driver;
- preventing the second device driver from writing a value to the second portion of the bit positions if the first device driver is granted access to the storage device;
- and
- preventing the first device driver from writing a value to the first portion of the bit positions if the second device driver is granted access to the storage device.
A computer readable storage medium comprising program instructions for controlling access to a plurality of devices through a shared storage device, wherein the storage device comprises a plurality of bit positions coupled to a plurality of electrical terminals, wherein values stored in the bit positions are used to control the operations of the plurality of devices, wherein a first portion of the electrical terminals is coupled to a first device, wherein a second portion of the electrical terminals is coupled to a second device, and wherein the program instructions are operable to implement:
- a first access to the storage device, wherein the first access is initiated by a first device driver and is configured to write a value to a first portion of the bit positions;
- a second access to the storage device, wherein the second access is initiated by a second device driver and is configured to write a value to a second portion of the bit positions;
- and
- a nexus device driver configured to grant exclusive access to the storage device to either the first or the second device driver;
- wherein said granting exclusive access comprises:
- detecting that a given device driver is attempting to modify one or more of the bit positions;
- determining which of the bit positions the given device driver owns;
- preventing the given device driver from modifying any of the bit positions of the storage device if one or more of the bit positions that the given device driver is attempting to modify is not owned by the given device driver;
- granting the given device driver access to the storage device if all of the bit positions the given device driver is attempting to modify are owned by the given device driver;
- preventing the second device driver from writing a value to the second portion of the bit positions if the first device driver is granted access to the storage device;
- and
- preventing the first device driver from writing a value to the first portion of the bit positions if the second device driver is granted access to the storage device.
Dependencies are inferred from the claim text.