Claims
- 1. Apparatus for controlling access to and use of stored elements by a processor that requests said access by identifying one of said stored elements and indicating an indicated use for said one stored element from a set of uses, said apparatus comprising:
- a memory that includes a plurality of regions each of which stores multiple said stored elements,
- storage for a plurality of records each of which corresponds to one region of said plurality of regions and includes access information that defines uses in said set of uses for which said processor is permitted to access said one region and use information stored separately from said access information, said use information designating one or more uses for the multiple stored elements stored in said one region from said set of uses, and
- a controller for responding to one of said requests by:
- examining the access information in a corresponding record for a particular region in which the stored element identified in the request is stored and selectively granting said processor access to said particular region if said access information indicates that said processor is permitted to access said particular region for said indicated use, and
- if said access is granted, then examining the use information is said corresponding record and regulating use of said element by said processor based on said use information and said indicated use.
- 2. The apparatus of claim 1 wherein said processor selectively operates in a user mode or a kernel mode, said access information defining the uses in said set of uses for which said processor is permitted to access said region which corresponds to said record for each one of said user and kernel modes, said controller selectively granting said access to said stored elements according to the one of said user and kernel modes in which the processor is operating and said access information for said one mode.
- 3. The apparatus of claim 1 wherein said stored elements include instruction elements and a use from said set of uses is execution, said controller responding to one of said requests that identifies an instruction element as said one stored element by using said use information to prevent said processor from using said instruction element unless said indicated use is execution.
- 4. The apparatus of claim 1 wherein said processor includes a cache memory unit, said apparatus further comprising an address controller responsive to address information in each one of said records for addressing elements in said cache memory unit.
- 5. The apparatus of claim 1 wherein said processor generates a plurality of virtual addresses for said stored elements and a first address space number associated with each of said virtual addresses, said apparatus further comprising:
- a translation buffer for translating said virtual addresses to physical addresses, said translation buffer having a second address space number corresponding to each virtual address to be translated; and
- a comparator which compares, for each virtual address to be translated by said translation buffer, said first address space number corresponding to said virtual address with the corresponding said second address space number in response to address space number information in said record, said translation buffer being utilized to translate a virtual address only if said comparator determines that corresponding first and second address space numbers are identical.
- 6. The apparatus of claim 1 wherein said record includes information that identifies whether the stored elements in the region corresponding to said record may be stored in a virtual cache.
- 7. The apparatus of claim 1 wherein said controller includes means for informing an operating system if one of said requests indicates a selected one or more of said set of uses designated by the use information in the record that corresponds to the region in which the stored element identified in the request is stored.
- 8. The apparatus of claim 1 wherein said processor has a user mode of operation for executing nonprivileged instructions and a kernel mode of operation for executing nonprivileged and privileged instructions and said set of uses includes read and write, said access information comprising:
- a first field position enabling read access for said user mode;
- a second field position enabling write access for said user mode;
- a third field position enabling read access for said kernel mode; and
- a fourth field position enabling write access for said kernel mode.
- 9. The apparatus of claim 1 wherein said use information for each one of said regions is included in a use field in said record that corresponds to said region, said use field comprising:
- a first field position for indicating a fault if said processor requests a write operation;
- a second field position for indicating a fault if said processor requests a read operation; and
- a third field position for indicating a fault if said processor requests an execute operation.
- 10. The apparatus of claim 1 where each said record includes validity information that indicates whether elements stored in the region in said memory that corresponds to said record are valid.
- 11. The apparatus of claim 1 where said processor has a plurality of operating modes, said access information defining, for each of said plurality of operating modes, whether said processor is permitted access to said particular region, said controller being adapted to deny said request and generate an access violation unless a current operating mode of said processor is one which said access information defines as a mode for which access to said particular region is permitted.
- 12. The apparatus of claim 11 wherein said controller is adapted to deny said request regardless of the indicated use unless said current operating mode of said processor is one which said access information defines as a mode for which access to said particular region is permitted.
- 13. The apparatus of claim 1 where said use information can designate no, some, or all uses from said set of uses, said controller including means for invoking an exception routine if said indicated use is not designated by said use information.
- 14. The apparatus of claim 13 wherein said exception routine causes said processor to be denied said indicated use.
- 15. The apparatus of claim 13 wherein said exception routine allows said processor to perform said indicated use but causes an operating system to be informed that said indicated use is being performed.
- 16. The apparatus of claim 1 where said stored elements comprise different types of stored elements and said use information designates said one or more uses based on said element types, said controller regulating use of said stored element identified in said request by selectively granting or denying said indicated use based on the element type of said stored element identified in said request and said use information.
- 17. The apparatus of claim 16 where said element types include data elements and instruction elements, said controller being adapted to deny said indicated use if the stored element identified in the request is an instruction element unless the indicated use is execution.
- 18. The apparatus of claim 1 wherein said plurality of regions comprise pages of a virtual memory.
- 19. The apparatus of claim 18 wherein each one of said records comprises a page table entry for page to which said record corresponds, said access information and said use information being included in fields of said page table entry.
- 20. A method for controlling access to and use of stored elements by a processor of a kind that requests said access by identifying one of said stored elements and indicating an indicated use for said one stored element from a set of uses, said method comprising:
- providing a memory that includes a plurality of regions each of which stores multiple said stored elements,
- storing a plurality of records each of which corresponds to one region of said plurality of regions and includes access information that defines uses in said set of uses for which said processor is permitted to access said one region and use information stored separately from said access information, said use information designating one or more uses in said set of uses for the stored elements from said one region, and
- responding to one of said requests by:
- examining the access information in a corresponding record for a particular region in which the stored element identified in the request is stored and selectively granting said processor access to said particular region if said access information indicates that said processor is permitted to access said particular region for said indicated use, and
- if said processor is granted access, then examining the use information in said corresponding record and regulating use of said stored element by said processor based on said use information and said indicated use.
Parent Case Info
This is a continuation of application Ser. No. 07/471,055, filed Jan. 23, 1990, now abandoned, which is a continuation of Ser. No. 07/069,290, filed Jul. 1, 1987, now abandoned.
US Referenced Citations (30)
Foreign Referenced Citations (1)
Number |
Date |
Country |
1200919 |
Feb 1986 |
CAX |
Non-Patent Literature Citations (1)
Entry |
Deitel, An Introduction to O.S., pp. 198-208, Southeast Book Co. |
Continuations (2)
|
Number |
Date |
Country |
Parent |
471055 |
Jan 1990 |
|
Parent |
69290 |
Jul 1987 |
|