System Calls

Recall that there are three system calls for each extended attribute operation (get, set, and list), which differ in how the destination is specified. To avoid code duplication, the system calls are structured into two parts:

1. Find the instance of dentry associated with the target object.

2. Delegate further processing to a function common to all three calls.

Looking up the dentry instance is performed by user_path_walk, by user_path_walk_link, or by reading the dentry pointer contained in the file instance, depending on which system call was used. After this, a common basis for all three system call variants has been established.

In the case of setxattr, the common function used for further processing is setxattr; the associated code flow diagram is shown in Figure 11-2.

Continue reading here: Limitsh

Was this article helpful?

0 0