# US 2008/0301389 A1 · Memory-protection method and apparatus

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2008/0301389 A1
- Document ID: US20080301389A1
- Status: Published application
- Kind: A1
- Application number: 12/125,954
- Filed: 2008-05-23
- Published: 2008-12-04
- Earliest claimed: 2007-05-28
- Assignees: Samsung Electronics Co., Ltd.
- Inventors: Hyo-Jun KIM; Song-Ho YOON
- Web page: https://patentgrep.com/patent/US20080301389A1

## CPC

- G06F 9/4812: {by interrupt, e.g. masked}
- G06F 9/468: {Specific access rights for resources, e.g. using capability register}
- G06F 12/1441: {for a range}
- G06F 21/78: to assure secure storage of data (address-based protection against unauthorised use of memory G06F12/14; record carriers for use with machines and with at least a part designed to carry digital markings G06K19/00)
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A memory-protection method and apparatus is provided that can protect a memory that is used by components in a real time operating system environment (RTOS). The memory-protection method includes requesting access to a first memory region that a first component uses when the first component is called to execute a first task in a real time operating system, and permitting the first task to access the first memory region with reference to a task list that includes information on tasks which are permitted to access the first memory region.

## Claims

### Claim 1

A memory-protection method comprising:
requesting access to a first memory region that a first component uses if the first component is called to execute a first task in a real time operating system; and
permitting the first task to access the first memory region with reference to a task list that includes information on tasks which are permitted to access the first memory region.

### Claim 2 (depends on 1)

The memory-protection method of claim 1, further comprising creating a page table that indicates corresponding relations of virtual addresses of the first memory region to physical addresses.

### Claim 3 (depends on 2)

The memory-protection method of claim 2, wherein the creating the page table further comprises:
grouping memory address spaces in a specified unit;
allocating the grouped address spaces to components; and
storing corresponding relations of the allocated address spaces to the components.

### Claim 4 (depends on 3)

The memory-protection method of claim 3, wherein the specified unit is a page composed of one address space or a plurality of successive address spaces.

### Claim 5 (depends on 3)

The memory-protection method of claim 3, further comprising initializing the page table so as to inhibit access to the grouped address spaces.

### Claim 6 (depends on 1)

The memory-protection method of claim 1, further comprising storing information on the first task to which access is permitted in the task list;
wherein the information includes at least one of an identifier of the first task and a number of times the first task requests permission to access the first memory region.

### Claim 7 (depends on 6)

The memory-protection method of claim 6, wherein the storing the information on the first task in the task list comprises adding the information on the first task to the task list if the access of the first task to the first memory region is not permitted.

### Claim 8 (depends on 6)

The memory-protection method of claim 6, wherein the storing the information on the first task comprises increasing the number of times the first task requests the access permission if the access of the first task to the first memory region has already been permitted.

### Claim 9 (depends on 6)

The memory-protection method of claim 6, further comprising:
requesting inhibition of access to the first memory region if the first task of which the access is permitted is completed; and
inhibiting the access to the first memory region.

### Claim 10 (depends on 9)

The memory-protection method of claim 9, wherein the inhibiting the access to the first memory region comprises:
decreasing the number of times the first task requests the access permission; and
if the decreased number of times the first task requests the access permission is “0”, deleting the information on the first task from the task list.

### Claim 11 (depends on 1)

The memory-protection method of claim 1, further comprising:
if a second task calls the first component in a state that the first task has called the first component, searching for information on the second task in the task list; and
if the information on the second task exists in the task list, permitting the second task to access the first memory region.

### Claim 12 (depends on 11)

The memory-protection method of claim 11, further comprising: if the information on the second task does not exist in the task list, generating an error.

### Claim 13 (depends on 1)

The memory-protection method of claim 1, further comprising if an interrupt is generated in a state that the first task has called the first component, inhibiting the access to the entire memory region.

### Claim 14 (depends on 13)

The memory-protection method of claim 13, further comprising:
if the first task accesses the first memory region after the interrupt is generated, generating a page fault;
searching for the information on the first task in the task list; and
if the information on the first task exists in the task list, permitting the first task to access the first memory region.

### Claim 15 (depends on 14)

The memory-protection method of claim 14, further comprising generating an error if the information on the first task does not exist in the task list.

### Claim 16

A memory-protection apparatus comprising:
a request unit which requests access to a first memory region that a first component uses when the first component is called to execute a first task in a real time operating system; and
a memory-access controller which permits the first task to access the first memory region with reference to a task list that includes information on tasks of which the access to the first memory region is permitted.

### Claim 17 (depends on 16)

The memory-protection apparatus of claim 16, further comprising a memory manager which creates a page table that indicates corresponding relations of virtual addresses of the first memory region to physical addresses.

### Claim 18 (depends on 17)

The memory-protection apparatus of claim 17, wherein the memory manager groups memory address spaces in a specified unit, allocates a grouped address spaces to components, and stores corresponding relations of the allocated address spaces to the components.

### Claim 19 (depends on 18)

The memory-protection apparatus of claim 18, wherein the unit is a page composed of one address space or a plurality of successive address spaces.

### Claim 20 (depends on 18)

The memory-protection apparatus of claim 18, wherein the memory manager initializes the page table so as to inhibit an access to the grouped address spaces.

### Claim 21 (depends on 16)

The memory-protection apparatus of claim 16, wherein the memory-access controller stores information on the first task of which the access is permitted in the task list, and the information includes at least one of an identifier of the first task and a number of times the first task requests permission to access the first memory region.

### Claim 22 (depends on 21)

The memory-protection apparatus of claim 21, wherein the memory-access controller adds the information on the first task to the task list if the access of the first task to the first memory region is not permitted.

### Claim 23 (depends on 21)

The memory-protection apparatus of claim 21, wherein the memory-access controller increases the number of times the first task requests the access permission if the access of the first task to the first memory region has already been permitted.

### Claim 24 (depends on 21)

The memory-protection apparatus of claim 21, wherein the memory-access controller inhibits the access to the first memory region if the first task of which the access is permitted is completed and thus a request for inhibition of access to the first memory region is requested.

### Claim 25 (depends on 24)

The memory-protection apparatus of claim 24, wherein the memory-access controller decreases the number of times the first task requests the access permission, and if the decreased number of times the first task requests the access permission is “0”, it deletes the information on the first task from the task list.

### Claim 26 (depends on 16)

The memory-protection apparatus of claim 16, wherein the memory-access controller searches for information on the second task in the task list if a second task calls the first component in a state that the first task has called the first component, and permits the second task to access the first memory region if the information on the second task exists in the task list.

### Claim 27 (depends on 26)

The memory-protection apparatus of claim 26, wherein the memory-access controller generates an error if the information on the second task does not exist in the task list.

### Claim 28 (depends on 16)

The memory-protection apparatus of claim 16, further comprising an interrupt handler inhibiting access to the entire memory region if an interrupt is generated in a state where the first task has called the first component.

### Claim 29 (depends on 28)

The memory-protection apparatus of claim 28, further comprising an exception handler searching for the information on the first task in the task list if the first task accesses the first memory region after the interrupt is generated and thus a page fault is generated, and permitting the first task to access the first memory region if the information on the first task exists in the task list as a result of searching.

### Claim 30 (depends on 29)

The memory-protection apparatus of claim 29, wherein the exception handler generates an error if the information on the first task does not exist in the task list.
