gidCount
@@ -89,8 +89,8 @@ After being started by the init process, the appspawn process waits for inter-pr
### Available APIs
-**Table 2** Available APIs
-Field
+**Table 2** API description
+API
|
Description
|
diff --git a/en/device-dev/subsystems/subsys-dfx-hilog-rich.md b/en/device-dev/subsystems/subsys-dfx-hilog-rich.md
index 79ad099abc4c457820e28c8929622135930728a9..e9d31ea25c72e2b253f00f8e0aaa1db95050cb2a 100644
--- a/en/device-dev/subsystems/subsys-dfx-hilog-rich.md
+++ b/en/device-dev/subsystems/subsys-dfx-hilog-rich.md
@@ -4,11 +4,11 @@
HiLog is the log system of OpenHarmony that provides logging for the system framework, services, and applications to record information on user operations and system running status.
-This development guide is applicable to Standard-System Devices \(reference memory ≥ 128 MB\).
+This development guide is applicable to standard-system devices \(reference memory ≥ 128 MB\).
## Available APIs
-**Table 1** Description of C++ and C APIs
+**Table 1** List of C++ and C APIs
C++
diff --git a/en/device-dev/subsystems/subsys-security-overview.md b/en/device-dev/subsystems/subsys-security-overview.md
index 52a022fdfc2d138c84b46aca02648d7e9f8c6039..7746a8d2680e3621551e3619ff6225dd58640518 100644
--- a/en/device-dev/subsystems/subsys-security-overview.md
+++ b/en/device-dev/subsystems/subsys-security-overview.md
@@ -1,60 +1,57 @@
-# Overview
+# Overview
The OpenHarmony security subsystem provides security capabilities that make your applications and devices more secure and help you manage permissions. This subsystem has the following modules:
-- Application signature verification
- To ensure the content integrity of applications, the system controls sources of the applications through application signatures and profiles. For a debugging application, the system uses the signature verification API to check whether the Unique Device Identifier (UDID) of the application matches that of the device, so as to ensure that the application is installed on the right device.
+- Application signature verification
-- Application permission management
+ To ensure the content integrity of applications, the system controls sources of the applications through application signatures and profiles. For a debugging application, the system uses the signature verification API to check whether the Unique Device Identifier (UDID) of the application matches that of the device, so as to ensure that the application is installed on the right device.
- Application permissions determine what system resources and capabilities an application can access. During application development, you need to declare the permissions that the application may require in the **profile.json** file. Static permissions need to be registered during application installation, while dynamic permissions usually involve sensitive information and need users' dynamic authorization.
+- Application permission management
-- Trusted device group management
+ Application permissions determine what system resources and capabilities an application can access. During application development, you need to declare the permissions that the application may require in the profile.json file. Static permissions need to be registered during application installation, while dynamic permissions usually involve sensitive information and need users' dynamic authorization.
- You can create and query a group of trusted devices that use the same HUAWEI ID or a peer-to-peer group created by scanning a QR code or using OneHop. With this capability, distributed applications can perform trusted authentication between devices and request from the distributed virtual bus for secure sessions between devices.
+- Inter-process communication (IPC) authentication
-- DSLM
+ The caller that attempts to invoke the APIs provided by system services through IPC must be authenticated. The system services registered with Samgr can expose APIs to other processes through IPC, with access policies configured. When other processes attempt to call these APIs, the IPC authentication mechanism will be triggered. If the processes do not have the access permission, the access request will be rejected.
- The OpenHarmony Device Security Level Management (DSLM) module manages the security levels of OpenHarmony devices. When different types of user data are hopped or processed in OpenHarmony distributed services, the DSLM APIs can be called to obtain the security levels of related devices for subsequent processing.
+- DSLM
+ The Device Security Level Management (DSLM) module is introduced to manage the security levels of OpenHarmony devices. When different types of user data are hopped or processed in OpenHarmony distributed services, the DSLM APIs can be called to obtain the security levels of related devices for subsequent processing.
-## Basic Concepts
-Before developing an application that depends on the signature verification component, you should understand the following basic concepts:
-
-- Samgr
-
- System Ability Manager (Samgr) is a module of OpenHarmony for managing system capabilities. For details, see the Application Framework development guidelines.
+## Basic Concepts
+Before developing an application that depends on the signature verification component, you should understand the following basic concepts:
-- BMS
-
- Bundle Manager Service (BMS) manages application installation, uninstallation, and data on OpenHarmony.
+- Samgr
+ System Ability Manager (Samgr) is a module of OpenHarmony for managing system capabilities. For details, see the Application Framework development guidelines.
-- Profile
+- BMS
- The profile in this document refers to HarmonyAppProvision (profile for short). HarmonyAppProvision is in JSON format.
+ Bundle Manager Service (BMS) manages application installation, uninstallation, and data on OpenHarmony.
+- Profile
-- Debugging application
+ The profile in this document refers to HarmonyAppProvision, which is in JSON format.
- A debugging application is a HarmonyOS Ability Package (HAP) that is signed with a debugging certificate and profile obtained from the application market.
+- Debug application
+ A debug application is an OpenHarmony Ability Package (HAP) that is signed with a debug certificate and profile obtained from the application store.
-- Released application
+- Release application
- This application refers to a HAP that is signed with a distribution certificate and profile obtained from the application market, but has been released in the application market.
+ A release application is a HAP that is signed with a release certificate and profile obtained from the application store, and formally released in the application store.
+- OpenHarmony self-signed application
-- OpenHarmony self-signed application
+ A self-signed application is an application that is signed with the signing certificate and profile issued by OpenHarmony's open-source root CA, which is composed of a certificate and a key.
- A self-signed application is one that has been signed with the signing certificate and profile issued by OpenHarmony's open-source root CA, which consists of a certificate and a key.
+## Constraints
-## Constraints
+- Only signatures of the debug, release, and OpenHarmony self-signed applications can be verified.
-- Only signatures of debugging, released, and OpenHarmony self-signed applications can be verified.
-- To verify the signature of a debugging application, the UDID of the device on which the debugging application is installed must be in the UDID list contained in the profile.
+- To verify the signature of a debug application, the UDID of the device on which the debug application is installed must be in the UDID list contained in the profile.
diff --git a/en/device-dev/subsystems/subsys-security.md b/en/device-dev/subsystems/subsys-security.md
index 0a63d0bb54fa3734ee51d1b2a7c0e2744085d1c7..1ea65be900fc2a6f2bbaa97c697d6c22a33e3230 100644
--- a/en/device-dev/subsystems/subsys-security.md
+++ b/en/device-dev/subsystems/subsys-security.md
@@ -2,7 +2,7 @@
- **[Overview](subsys-security-overview.md)**
-- **[Development on Application Signature Verification] (subsys-security-sigverify.md)**
+- **[Development on Application Signature Verification](subsys-security-sigverify.md)**
- **[Development on Application Permission Management](subsys-security-rightmanagement.md)**
diff --git a/en/device-dev/subsystems/subsys-toolchain-hiperf.md b/en/device-dev/subsystems/subsys-toolchain-hiperf.md
deleted file mode 100644
index 213f606ba2163da611bd074e5aba5c89cb5b3718..0000000000000000000000000000000000000000
--- a/en/device-dev/subsystems/subsys-toolchain-hiperf.md
+++ /dev/null
@@ -1,535 +0,0 @@
-# hiperf
-
-- [list](#section121805449461)
- - [Parameters](#section42124492494)
- - [Example](#section122129443486)
-
-- [stat](#section12940163061016)
- - [Parameters](#section36541920145018)
- - [Example](#section1132495515502)
- - [Field Description](#section1958985055118)
-
-- [record](#section168751927524)
- - [Parameters](#section113617912522)
- - [Example](#section15998181516549)
-
-- [report](#section16327635174818)
-- [Example](#section1197655116513)
-
-hiperf is a performance sampling and analysis tool provided for developers. It extends the user-mode capabilities based on the kernel perf mechanism and can conduct performance sampling of the specified application or the entire system.
-
-You can run the **hiperf -h** command to display the commands supported by hiperf.
-
-The following describes the common commands \(**list**, **stat**, **record**, and **report**\) supported by hiperf.
-
-## list
-
-### Parameters
-
-The **list** command lists all the perf events supported by the device. The event names are used for the **-e** and **-g** parameters of the **stat** and **record** commands.
-
-```
-hiperf list [event type]
-```
-
-
-Parameter
- |
-Description
- |
-
-
-hw
- |
-Lists the hardware events supported by the performance monitoring unit (PMU).
- |
-
-sw
- |
-Lists the software events supported.
- |
-
-tp
- |
-Lists the tracepotint events supported.
- |
-
-cache
- |
-Lists the cache events supported by the PMU.
- |
-
-raw
- |
-Lists the raw PMU events supported.
- |
-
-
-
-
-### Example
-
-List the hardware events supported by the PMU. The command also lists the events that are not supported by the PMU.
-
-```
-hiperf list hw
-event not support hw-stalled-cycles-backend
-event not support hw-stalled-cycles-frontend
-event not support hw-ref-cpu-cycles
-
-Supported events for hardware:
- hw-cpu-cycles
- hw-instructions
- hw-cache-references
- hw-cache-misses
- hw-branch-instructions
- hw-branch-misses
- hw-bus-cycles
-```
-
-## stat
-
-### Parameters
-
-The **stat** command monitors the specified application and periodically prints the values of performance counters.
-
-```
-hiperf stat [options]
- Collect performance counter information.
-```
-
-
-Parameter
- |
-Description
- |
-
-
--a
- |
-Collects the values of all threads and default performance counters of the system.
- |
-
--c
- |
-Specifies the IDs of the CPUs to monitor. Use commas (,) to separate multiple CPU IDs, for example 0,1,2.
- |
-
--d <sec>
- |
-Specifies the monitoring period, in seconds.
- |
-
--i <ms>
- |
-Specifies the interval for printing the monitored events, in milliseconds.
- |
-
--e
- |
-Specifies the events to monitor. You can run the list command to list all the events supported. event:u indicates an event in the user space, and event:k indicates an event in the kernel space.
- |
-
--g
- |
-Specifies a group of events to monitor. The events in the same group are monitored by the same PMU.
- |
-
---no-inherit
- |
-Leaves the sub-threads of the target thread or process not monitored.
- |
-
--p
- |
-Specifies the process IDs (PIDs) to monitor.
- |
-
--t
- |
-Specifies the thread IDs (TIDs) to monitor.
- |
-
---verbose
- |
-Displays detailed report, including raw time data.
- |
-
-
-
-
-### Example
-
-Monitor the entire system for 3 seconds.
-
-```
-hiperf stat -d 3 -a
-this is root mode, perfEventParanoid assume as -1
-Start Profiling...
-Timeout exit (total 3009 ms)
- count name | comment | coverage
- 132523 hw-branch-instructions | 15.750 M/sec | (100%)
- 62554 hw-branch-misses | 47.202372% miss rate | (100%)
- 6994768 hw-cpu-cycles | 0.832068 GHz | (100%)
- 1237627 hw-instructions | 5.651758 cycles per instruction | (100%)
- 248 sw-context-switches | 29.959 K/sec | (100%)
- 0 sw-page-faults | 0.000 /sec | (100%)
- 9402580 sw-task-clock | 0.002758 cpus used | (100%)
-```
-
-### Field Description
-
-
-Field
- |
-Description
- |
-
-
-count
- |
-Indicates the times that an event occurred.
- |
-
-name
- |
-Indicates the event name. You can run the list command to list all the supported events. hw stands for hardware, and sw stands for software.
- |
-
-comment
- |
-Provides values calculated from those in the Count column for easy understanding. For example, the CPU frequency (hw-cpu-cycles) is converted to 0.832068 GHz from 6994768.
- |
-
-coverage
- |
-Indicates the percentage of PMU resources occupied by the event. The number of events to be monitored by a PMU varies depending on the number of PMUs.
- |
-
-
-
-
-## record
-
-### Parameters
-
-The **record** command samples the specified application and saves the sampling data to a file \(**perf.data** by default\).
-
-```
-hiperf record [options]
- Collect performance sampling information.
-```
-
-
-Parameter
- |
-Description
- |
-
-
--a
- |
-Samples all processes and threads in the system.
- |
-
---exclude-hiperf
- |
-Leaves the hiperf process not sampled.
- |
-
--c
- |
-Specifies the IDs of the CPUs to sample.
- |
-
---cpu-limit <percent>
- |
-Specifies the maximum percentage of CPU resources occupied by the sampling.
- |
-
--d <sec>
- |
-Specifies the sampling duration, in seconds.
- |
-
--f <freq>
- |
-Specifies how often a sampling event is triggered. The default value is 4000 times/second.
-Note: A higher value indicates heavier CPU load but more sampling data.
- |
-
---period <num>
- |
-Specifies the number of occurrence times of an event that triggers a sampling. That is, a sampling is performed once when the event occurs the specified number of times.
- |
-
--e
- |
-Specifies the events to monitor. You can run the list command to list all the events supported. event:u indicates an event in the user space, and event:k indicates an event in the kernel space.
- |
-
--g
- |
-Specifies a group of events to monitor. The events in the same group are monitored by the same PMU.
- |
-
---no-inherit
- |
-Leaves the sub-threads of the target thread or process not monitored.
- |
-
--p
- |
-Specifies the processes to monitor.
- |
-
--t
- |
-Specifies the threads to monitor.
- |
-
---offcpu
- |
-Monitors the CPU scheduling event, which is equivalent to the --period 1 -e sched:sched_switch event.
- |
-
--j <branch_filter1>[,branch_filter2]...
- |
-Monitors the branch prediction events. Branch prediction tries to predict the next instruction to be executed if there are multiple if else conditions.
- |
-
--s / --call-stack <fp \| dwarf[,size]>
- |
-Sets the user stack unwinding mode, which can be fp or dwarf. If dwarf is used, you can specify the size of the user stack to be sampled. The default value is 65528.
- |
-
---delay-unwind
- |
-Delays the stack unwinding till the sampling is complete.
- |
-
---disable-unwind
- |
-Disables stack unwinding. The user register and stack data is stored in perf.data for offline stack unwinding.
- |
-
---disable-callstack-expend
- |
-Disables the unwound call stack information from being combined or extended.
- |
-
---clockid <clock type>
- |
-Sets the clock source for the sampling data. The options are monotonic, boottime, and realtime.
- |
-
---symbol-dir <dir>
- |
-Specifies the directory of the symbol table. The specified symbol table will be preferentially used in stack unwinding.
- |
-
--m <mmap pages>
- |
-Specifies the cache size, in pages. The default value is 1024. The parameter value must be a power of 2. The value range is [2 - 1024].
-Note: A higher value indicates a lower event loss rate but higher memory usage.
- |
-
---app <package name>
- |
-Specifies the bundle name of the target application to be sampled. The default timeout interval is 10 seconds. If the specified application does not exist, the hiperf process exits after 10 seconds.
- |
-
---data-limit <SIZE[K|M|G]>
- |
-Specifies the maximum size of the sampling result, in KB, MB, or GB. By default, there is no limit on the size.
- |
-
--o <output file name>
- |
-Specifies the name of the sampling result file. It is /data/local/tmp/perf.data by default.
- |
-
--z
- |
-Saves the output file in .gzip format.
- |
-
---verbose
- |
-Displays detailed log information during sampling.
- |
-
-
-
-
-### Example
-
-- Sample all processes in the system for 3 seconds and display detailed log information during the sampling process.
-
- ```
- hiperf record -d 3 -a --verbose
- ```
-
-
-- Enable stack unwinding in fp mode.
-
- ```
- hiperf record -s fp -d 3 -a
- ```
-
-- Enable stack unwinding in dwarf mode.
-
- ```
- hiperf record -s dwarf -d 3 -a
- ```
-
-- Sample offcpu events.
-
- ```
- hiperf record --offcpu -s dwarf -d 3 -a
- ```
-
-- Delay stack unwinding.
-
- ```
- hiperf record -d 3 -s dwarf --delay-unwind -a
- ```
-
-- Disable stack unwinding. In this case, the stack data is saved to the **perf.data** file.
-
- ```
- hiperf record -d 3 -s dwarf --disable-unwind -a
- ```
-
-- Monitor the **com.ohos.launch** application. The hiperf process exits after 10 seconds if the process corresponding to the specified bundle name does not exist.
-
- ```
- hiperf record -d 3 -s dwarf --app com.ohos.launch
- ```
-
-- Compress the sampling results.
-
- ```
- hiperf record -z -s dwarf -d 3 -a
- ```
-
-
-## report
-
-The **report** command displays the sampling data that is captured by using **record**.
-
-```
-hiperf report [option]
- Report sampling information from perf.data.
-```
-
-
-Parameter
- |
-Description
- |
-
-
---symbol-dir <dir>
- |
-Specifies the directory of the symbol table.
- |
-
---limit-percent <number>
- |
-Specifies the minimum percentage of the result to display. The result that is lower than the minimum percentage is not displayed.
- |
-
--s / --call-stack
- |
-Displays detailed call stack information.
- |
-
---call-stack-limit-percent <number>
- |
-Specifies the minimum percentage of the call stack to display. The call stack that is lower than the minimum percentage is not displayed.
- |
-
---proto
- |
-Converts the perf.data file into the proto format. The default file name is perf.proto.
- |
-
---json
- |
-Converts the perf.data file into the JSON format. The default file name is perf.json.
- |
-
---branch
- |
-Displays the report based on the branch prediction result address instead of the IP address of the call stack.
- |
-
---<keys> <keyname1>[,keyname2][,...]
- |
-Filters and displays reports based on the given keywords. keys can be comms, pids, and tids. For example, --comms hiperf,hilog displays only the records whose process or thread name is hiperf or hilog.
- |
-
---sort <key1>[,key2][,...]
- |
-Sorts and displays information based on specified keywords, such as pid, tid, and comm. Multiple keywords can be specified.
- |
-
--i <filename>
- |
-Specifies the sampling data (perf.data by default).
- |
-
--o <filename>
- |
-Specifies the name of the report to output.
- |
-
-
-
-
-## Example
-
-- Output the report of the sampling data \(**perf.data** by default\).
-
- ```
- hiperf report
- ```
-
- Output \(example\):
-
- ```
- Heating count comm pid tid dso func
- 5.68% 15073949 hiperf_example_ 1085 1091 /system/lib/ld-musl-arm.so.1 malloc
- 2.57% 6834119 hiperf_example_ 1085 1091 [kernel.kallsyms] vector_swi
- 2.27% 6013910 hiperf_example_ 1085 1087 /system/lib/ld-musl-arm.so.1 malloc
- 2.19% 5805738 hiperf_example_ 1085 1091 /system/lib/ld-musl-arm.so.1 vfprintf
- 2.09% 5543362 hiperf_example_ 1085 1091 [kernel.kallsyms] ktime_get_ts64
- report done
- ```
-
-- Output the call stack report of the sampling data.
-
- ```
- hiperf report -s
- ```
-
-- Set the symbol table directory.
-
- ```
- hiperf report -s --symbol-dir /data/local/tmp
- ```
-
-- Display only the information containing **libutils.z.so**.
-
- ```
- hiperf report --dsos libuitls.z.so
- ```
-
-- Sort the result by **dso**.
-
- ```
- hiperf report --sort dso
- ```
-
-
diff --git a/en/device-dev/subsystems/subsys-usbservice-demo.md b/en/device-dev/subsystems/subsys-usbservice-demo.md
index decf0dad73249125e04804a2674ddb41fa002995..80506e955cea844f4cca1b3552f0f1828fcc77f8 100644
--- a/en/device-dev/subsystems/subsys-usbservice-demo.md
+++ b/en/device-dev/subsystems/subsys-usbservice-demo.md
@@ -1,4 +1,4 @@
-# USB Usage Example
+# USB Usage Demo
```
@@ -183,5 +183,3 @@ int main(int argc, char **argv)
return 0;
}
```
-
-
diff --git a/en/device-dev/subsystems/subsys-usbservice-guide.md b/en/device-dev/subsystems/subsys-usbservice-guide.md
index aef72208f914db636a4827ea0ff0a06c164c242c..6ccfc2594dafaab234dac597c3aee24b1d60ccb5 100644
--- a/en/device-dev/subsystems/subsys-usbservice-guide.md
+++ b/en/device-dev/subsystems/subsys-usbservice-guide.md
@@ -1,5 +1,6 @@
# USB Usage Guidelines
+
The following procedure uses bulk transfer as an example.
## Procedure
@@ -42,7 +43,10 @@ ret = g_usbClient.ClaimInterface(pip, interface, true);
```
srvClient.BulkTransfer(pipe, endpoint, vdata, timeout);
```
-**pipe** indicates the pipe for data transfer after the USB device is opened. **endpoint** indicates the endpoint for data transfer on the USB device. **vdata** indicates the binary data block to be transferred or read. **timeout** indicates the timeout duration of data transfer.
+- **pipe** indicates the pipe for data transfer of the USB device opened.
+- **endpoint** indicates the endpoint for data transfer on the USB device.
+- **vdata** indicates the binary data block to be transferred or read.
+- **timeout** indicates the timeout duration of data transfer.
7. Close the USB device.
diff --git a/en/device-dev/subsystems/subsys-xts-guide.md b/en/device-dev/subsystems/subsys-xts-guide.md
index 70951c0d1e3ef8da140f58bdb67831901ce48793..8edb14f97ee25a560587fbe9b875e5b9aaf5d50e 100644
--- a/en/device-dev/subsystems/subsys-xts-guide.md
+++ b/en/device-dev/subsystems/subsys-xts-guide.md
@@ -2,7 +2,7 @@
## Introduction
-The X test suite \(XTS\) subsystem contains a set of OpenHarmony certification test suites, including the currently supported application compatibility test suite \(ACTS\) and the device compatibility test suite \(DCTS\) that will be supported in the future.
+The X test suite \(XTS\) subsystem contains a set of OpenHarmony compatibility test suites, including the currently supported application compatibility test suite \(ACTS\) and the device compatibility test suite \(DCTS\) that will be supported in the future.
This subsystem contains the ACTS and **tools** software package.
@@ -690,7 +690,7 @@ Install Python 3.7 or a later version on a Windows environment and ensure that t
Wait until the test case is complete.
-1. View test reports.
+3. View test reports.
Go to **acts\\reports\\**, obtain the current execution record, and open **summary\_report.html** to view the test report.
diff --git a/en/device-dev/website.md b/en/device-dev/website.md
index 1ca0f668d0b4033c7c2bc4c6e3eddc27171c80ab..6fd7fe16d41c26589bfa34f443aa860ac976ecde 100644
--- a/en/device-dev/website.md
+++ b/en/device-dev/website.md
@@ -384,10 +384,10 @@
- [HiSysEvent Query](subsystems/subsys-dfx-hisysevent-query.md)
- [HiSysEvent Tool Usage](subsystems/subsys-dfx-hisysevent-tool.md)
- Featured Topics
- - HPM Bundle
- - [HPM Part Overview](bundles/hpm-part-about.md)
- - [HPM Part Development](bundles/hpm-part-development.md)
- - [HPM Part Reference](bundles/hpm-part-reference.md)
+ - HPM Part
+ - [HPM Part Overview](hpm-part/hpm-part-about.md)
+ - [HPM Part Development](hpm-part/hpm-part-development.md)
+ - [HPM Part Reference](hpm-part/hpm-part-reference.md)
- Device Development Examples
- [Mini- and Small-System Devices](guide/device-lite.md)
- [WLAN-connected Products](guide/device-wlan.md)
|
|---|
|---|
|
|---|
|