website: Optimize the non-GKI page format and repair errors (#1141)

1. Divide the patches into a separate file segment
2. Fix the ISO C90 grammar warning in fs/open.c

Conflict: JA_JP Folder does not do how-to-integrate-for-non-gki.md
Change-Id: I23a611eb937d9cb3da7a2d97046e0b57f1efc4d6

Co-authored-by: admin <paper@localhost>
This commit is contained in:
Aquarius223 2023-11-14 11:06:44 +08:00 committed by GitHub
parent 8196243478
commit b45c4f57c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 105 additions and 14 deletions

View File

@ -91,7 +91,8 @@ index ac59664eaecf..bdd585e1d2cc 100644
+ ksu_handle_execveat_sucompat(&fd, &filename, &argv, &envp, &flags);
return __do_execve_file(fd, filename, argv, envp, flags, NULL);
}
```
```diff
diff --git a/fs/open.c b/fs/open.c
index 05036d819197..965b84d486b8 100644
--- a/fs/open.c
@ -109,10 +110,20 @@ index 05036d819197..965b84d486b8 100644
*/
long do_faccessat(int dfd, const char __user *filename, int mode)
{
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
const struct cred *old_cred;
struct cred *override_cred;
struct path path;
struct inode *inode;
struct vfsmount *mnt;
int res;
unsigned int lookup_flags = LOOKUP_FOLLOW;
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
if (mode & ~S_IRWXO) /* where's F_OK, X_OK, W_OK, R_OK? */
return -EINVAL;
```
```diff
diff --git a/fs/read_write.c b/fs/read_write.c
index 650fc7e0f3a6..55be193913b6 100644
--- a/fs/read_write.c
@ -134,6 +145,8 @@ index 650fc7e0f3a6..55be193913b6 100644
if (!(file->f_mode & FMODE_READ))
return -EBADF;
if (!(file->f_mode & FMODE_CAN_READ))
```
```diff
diff --git a/fs/stat.c b/fs/stat.c
index 376543199b5a..82adcef03ecc 100644
--- a/fs/stat.c

View File

@ -86,7 +86,8 @@ index ac59664eaecf..bdd585e1d2cc 100644
+ ksu_handle_execveat_sucompat(&fd, &filename, &argv, &envp, &flags);
return __do_execve_file(fd, filename, argv, envp, flags, NULL);
}
```
```diff
diff --git a/fs/open.c b/fs/open.c
index 05036d819197..965b84d486b8 100644
--- a/fs/open.c
@ -104,10 +105,20 @@ index 05036d819197..965b84d486b8 100644
*/
long do_faccessat(int dfd, const char __user *filename, int mode)
{
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
const struct cred *old_cred;
struct cred *override_cred;
struct path path;
struct inode *inode;
struct vfsmount *mnt;
int res;
unsigned int lookup_flags = LOOKUP_FOLLOW;
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
if (mode & ~S_IRWXO) /* where's F_OK, X_OK, W_OK, R_OK? */
return -EINVAL;
```
```diff
diff --git a/fs/read_write.c b/fs/read_write.c
index 650fc7e0f3a6..55be193913b6 100644
--- a/fs/read_write.c
@ -129,6 +140,8 @@ index 650fc7e0f3a6..55be193913b6 100644
if (!(file->f_mode & FMODE_READ))
return -EBADF;
if (!(file->f_mode & FMODE_CAN_READ))
```
```diff
diff --git a/fs/stat.c b/fs/stat.c
index 376543199b5a..82adcef03ecc 100644
--- a/fs/stat.c

View File

@ -91,7 +91,8 @@ index ac59664eaecf..bdd585e1d2cc 100644
+ ksu_handle_execveat_sucompat(&fd, &filename, &argv, &envp, &flags);
return __do_execve_file(fd, filename, argv, envp, flags, NULL);
}
```
```diff
diff --git a/fs/open.c b/fs/open.c
index 05036d819197..965b84d486b8 100644
--- a/fs/open.c
@ -109,10 +110,20 @@ index 05036d819197..965b84d486b8 100644
*/
long do_faccessat(int dfd, const char __user *filename, int mode)
{
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
const struct cred *old_cred;
struct cred *override_cred;
struct path path;
struct inode *inode;
struct vfsmount *mnt;
int res;
unsigned int lookup_flags = LOOKUP_FOLLOW;
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
if (mode & ~S_IRWXO) /* where's F_OK, X_OK, W_OK, R_OK? */
return -EINVAL;
```
```diff
diff --git a/fs/read_write.c b/fs/read_write.c
index 650fc7e0f3a6..55be193913b6 100644
--- a/fs/read_write.c
@ -134,6 +145,8 @@ index 650fc7e0f3a6..55be193913b6 100644
if (!(file->f_mode & FMODE_READ))
return -EBADF;
if (!(file->f_mode & FMODE_CAN_READ))
```
```diff
diff --git a/fs/stat.c b/fs/stat.c
index 376543199b5a..82adcef03ecc 100644
--- a/fs/stat.c

View File

@ -91,7 +91,8 @@ index ac59664eaecf..bdd585e1d2cc 100644
+ ksu_handle_execveat_sucompat(&fd, &filename, &argv, &envp, &flags);
return __do_execve_file(fd, filename, argv, envp, flags, NULL);
}
```
```diff
diff --git a/fs/open.c b/fs/open.c
index 05036d819197..965b84d486b8 100644
--- a/fs/open.c
@ -109,10 +110,20 @@ index 05036d819197..965b84d486b8 100644
*/
long do_faccessat(int dfd, const char __user *filename, int mode)
{
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
const struct cred *old_cred;
struct cred *override_cred;
struct path path;
struct inode *inode;
struct vfsmount *mnt;
int res;
unsigned int lookup_flags = LOOKUP_FOLLOW;
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
if (mode & ~S_IRWXO) /* where's F_OK, X_OK, W_OK, R_OK? */
return -EINVAL;
```
```diff
diff --git a/fs/read_write.c b/fs/read_write.c
index 650fc7e0f3a6..55be193913b6 100644
--- a/fs/read_write.c
@ -134,6 +145,8 @@ index 650fc7e0f3a6..55be193913b6 100644
if (!(file->f_mode & FMODE_READ))
return -EBADF;
if (!(file->f_mode & FMODE_CAN_READ))
```
```diff
diff --git a/fs/stat.c b/fs/stat.c
index 376543199b5a..82adcef03ecc 100644
--- a/fs/stat.c

View File

@ -87,7 +87,8 @@ index ac59664eaecf..bdd585e1d2cc 100644
+ ksu_handle_execveat_sucompat(&fd, &filename, &argv, &envp, &flags);
return __do_execve_file(fd, filename, argv, envp, flags, NULL);
}
```
```diff
diff --git a/fs/open.c b/fs/open.c
index 05036d819197..965b84d486b8 100644
--- a/fs/open.c
@ -105,10 +106,20 @@ index 05036d819197..965b84d486b8 100644
*/
long do_faccessat(int dfd, const char __user *filename, int mode)
{
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
const struct cred *old_cred;
struct cred *override_cred;
struct path path;
struct inode *inode;
struct vfsmount *mnt;
int res;
unsigned int lookup_flags = LOOKUP_FOLLOW;
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
if (mode & ~S_IRWXO) /* where's F_OK, X_OK, W_OK, R_OK? */
return -EINVAL;
```
```diff
diff --git a/fs/read_write.c b/fs/read_write.c
index 650fc7e0f3a6..55be193913b6 100644
--- a/fs/read_write.c
@ -130,6 +141,8 @@ index 650fc7e0f3a6..55be193913b6 100644
if (!(file->f_mode & FMODE_READ))
return -EBADF;
if (!(file->f_mode & FMODE_CAN_READ))
```
```diff
diff --git a/fs/stat.c b/fs/stat.c
index 376543199b5a..82adcef03ecc 100644
--- a/fs/stat.c

View File

@ -91,7 +91,8 @@ index ac59664eaecf..bdd585e1d2cc 100644
+ ksu_handle_execveat_sucompat(&fd, &filename, &argv, &envp, &flags);
return __do_execve_file(fd, filename, argv, envp, flags, NULL);
}
```
```diff
diff --git a/fs/open.c b/fs/open.c
index 05036d819197..965b84d486b8 100644
--- a/fs/open.c
@ -109,10 +110,20 @@ index 05036d819197..965b84d486b8 100644
*/
long do_faccessat(int dfd, const char __user *filename, int mode)
{
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
const struct cred *old_cred;
struct cred *override_cred;
struct path path;
struct inode *inode;
struct vfsmount *mnt;
int res;
unsigned int lookup_flags = LOOKUP_FOLLOW;
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
if (mode & ~S_IRWXO) /* where's F_OK, X_OK, W_OK, R_OK? */
return -EINVAL;
```
```diff
diff --git a/fs/read_write.c b/fs/read_write.c
index 650fc7e0f3a6..55be193913b6 100644
--- a/fs/read_write.c
@ -134,6 +145,8 @@ index 650fc7e0f3a6..55be193913b6 100644
if (!(file->f_mode & FMODE_READ))
return -EBADF;
if (!(file->f_mode & FMODE_CAN_READ))
```
```diff
diff --git a/fs/stat.c b/fs/stat.c
index 376543199b5a..82adcef03ecc 100644
--- a/fs/stat.c

View File

@ -91,7 +91,8 @@ index ac59664eaecf..bdd585e1d2cc 100644
+ ksu_handle_execveat_sucompat(&fd, &filename, &argv, &envp, &flags);
return __do_execve_file(fd, filename, argv, envp, flags, NULL);
}
```
```diff
diff --git a/fs/open.c b/fs/open.c
index 05036d819197..965b84d486b8 100644
--- a/fs/open.c
@ -109,10 +110,20 @@ index 05036d819197..965b84d486b8 100644
*/
long do_faccessat(int dfd, const char __user *filename, int mode)
{
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
const struct cred *old_cred;
struct cred *override_cred;
struct path path;
struct inode *inode;
struct vfsmount *mnt;
int res;
unsigned int lookup_flags = LOOKUP_FOLLOW;
+ ksu_handle_faccessat(&dfd, &filename, &mode, NULL);
if (mode & ~S_IRWXO) /* where's F_OK, X_OK, W_OK, R_OK? */
return -EINVAL;
```
```diff
diff --git a/fs/read_write.c b/fs/read_write.c
index 650fc7e0f3a6..55be193913b6 100644
--- a/fs/read_write.c
@ -134,6 +145,8 @@ index 650fc7e0f3a6..55be193913b6 100644
if (!(file->f_mode & FMODE_READ))
return -EBADF;
if (!(file->f_mode & FMODE_CAN_READ))
```
```diff
diff --git a/fs/stat.c b/fs/stat.c
index 376543199b5a..82adcef03ecc 100644
--- a/fs/stat.c