update openharmony 1.0.1

This commit is contained in:
mamingshuai
2021-03-11 18:43:57 +08:00
parent e351799d39
commit 73a7b66116
611 changed files with 17977 additions and 14077 deletions

6
fs/include/disk.h Normal file → Executable file
View File

@@ -1,6 +1,6 @@
/*
* Copyright (c) 2013-2019, Huawei Technologies Co., Ltd. All rights reserved.
* Copyright (c) 2020, Huawei Device Co., Ltd. All rights reserved.
* Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
* Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification,
* are permitted provided that the following conditions are met:
@@ -477,7 +477,7 @@ INT32 los_part_read(INT32 pt, VOID *buf, UINT64 sector, UINT32 count);
* @see los_part_read
*
*/
INT32 los_part_write(INT32 pt, VOID *buf, UINT64 sector, UINT32 count);
INT32 los_part_write(INT32 pt, const VOID *buf, UINT64 sector, UINT32 count);
/**
* @ingroup disk

View File

@@ -1,6 +1,6 @@
/*
* Copyright (c) 2013-2019, Huawei Technologies Co., Ltd. All rights reserved.
* Copyright (c) 2020, Huawei Device Co., Ltd. All rights reserved.
* Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
* Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification,
* are permitted provided that the following conditions are met:
@@ -39,13 +39,12 @@
/* open file table for process fd */
struct file_table_s {
signed short sysFd; /* system fd associate with the tg_filelist index */
intptr_t sysFd; /* system fd associate with the tg_filelist index */
};
struct fd_table_s {
unsigned int max_fds;
struct file_table_s *ft_fds; /* process fd array associate with system fd */
fd_set *open_fds;
fd_set *proc_fds;
sem_t ft_sem; /* manage access to the file table */
};
@@ -77,4 +76,5 @@ void delete_files_snapshot(struct files_struct *files);
int alloc_fd(int minfd);
void alloc_std_fd(struct fd_table_s *fdt);
#endif

4
fs/include/fs/fs_operation.h Normal file → Executable file
View File

@@ -1,6 +1,6 @@
/*
* Copyright (c) 2013-2019, Huawei Technologies Co., Ltd. All rights reserved.
* Copyright (c) 2020, Huawei Device Co., Ltd. All rights reserved.
* Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
* Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification,
* are permitted provided that the following conditions are met:

20
fs/include/vfs_config.h Normal file → Executable file
View File

@@ -1,6 +1,6 @@
/*
* Copyright (c) 2013-2019, Huawei Technologies Co., Ltd. All rights reserved.
* Copyright (c) 2020, Huawei Device Co., Ltd. All rights reserved.
* Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
* Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification,
* are permitted provided that the following conditions are met:
@@ -66,7 +66,7 @@ extern "C" {
/* config dirty ratio of bcache for fat file system */
#define CONFIG_FS_FAT_DIRTY_RATIO 80
#define CONFIG_FS_FAT_DIRTY_RATIO 60
/* config time interval of sync thread for fat file system, in milliseconds */
@@ -87,7 +87,11 @@ extern "C" {
#define CONFIG_STDIO_BUFFER_SIZE 0
#define CONFIG_NUNGET_CHARS 0
#define FD_SETSIZE (CONFIG_NFILE_DESCRIPTORS + CONFIG_NSOCKET_DESCRIPTORS) // total fds
#define FD_SET_TOTAL_SIZE (FD_SETSIZE + CONFIG_NEXPANED_DESCRIPTORS)
#define FD_SETSIZE (CONFIG_NFILE_DESCRIPTORS + CONFIG_NSOCKET_DESCRIPTORS)
#define CONFIG_NEXPANED_DESCRIPTORS (CONFIG_NTIME_DESCRIPTORS + CONFIG_NQUEUE_DESCRIPTORS)
#define TIMER_FD_OFFSET FD_SETSIZE
#define MQUEUE_FD_OFFSET (FD_SETSIZE + CONFIG_NTIME_DESCRIPTORS)
/* net configure */
@@ -109,6 +113,14 @@ extern "C" {
#define NR_OPEN_DEFAULT CONFIG_NFILE_DESCRIPTORS
/* time configure */
#define CONFIG_NTIME_DESCRIPTORS 0
/* mqueue configure */
#define CONFIG_NQUEUE_DESCRIPTORS 256
/* directory configure */
#define VFS_USING_WORKDIR // enable current working directory