Eladash
d0e31f4ec3
sys_fs: Add write log messages for SDATA/EDATA
2021-09-22 14:57:16 +03:00
Eladash
3e06446297
sys_fs: Fix sys_fs_read/write when nbytes is 0
2021-09-22 14:57:16 +03:00
Eladash
5ae7dbf77c
Fix cellFsSdataOpenByFd flags
2021-09-22 14:57:16 +03:00
Eladash
c7f5475b56
Improve sys_fs_close logging
2021-09-12 19:05:26 +03:00
clienthax
7fe15f5f8d
Stub sys_fs mount functions for vsh ( #10561 )
...
Co-authored-by: Eladash <elad3356p@gmail.com>
2021-07-17 19:19:13 +02:00
Eladash
58847fa2ca
sys_fs: Fix ENOTMOUNTED of open
2021-06-26 14:53:22 +03:00
Eladash
50be3bd2e5
kernel-explorer: devirtualize lv2_fs_object and print more information ( #10487 )
...
* Make lv2_fs_object an "abstract" structure with protected constructor.
* Improve kernel-explorer information for filesystem objects.
2021-06-24 16:47:14 +03:00
Nekotekina
72680c7707
sys_fs: improve sys_fs_open accuracy for /dev_bdvd
...
Based on software test.
2021-06-18 17:47:49 +03:00
clienthax
7197dd751a
Fcntl e0000025 ( #10172 )
...
Co-authored-by: Eladash <elad3356p@gmail.com>
2021-04-24 21:43:09 +03:00
clienthax
68fa377d13
Add dev_flash2+3
2021-04-18 14:49:29 +03:00
Megamouse
a16d8ba3ea
More random changes
2021-04-11 14:01:51 +03:00
Nekotekina
8fcebebae3
Implement lv2_mp_flag::cache
...
Identify /dev_hdd1 without unsafe path comparison.
2021-03-16 19:37:03 +03:00
Eladash
d7b4753007
Make gamedata installation atomic as real PS3
2021-03-16 19:31:52 +03:00
Nekotekina
87af905018
Enable -Wunused-parameter
2021-03-06 18:07:08 +03:00
Nekotekina
ea5e837bd6
fixed_typemap.hpp: return reference
2021-03-02 16:08:14 +03:00
Eladash
932f31e37b
Atomic PARAM.SFO writes
2021-02-23 11:29:23 +03:00
Nekotekina
db8e6fe7a7
Enable -Wunused-variable
2021-01-12 14:34:14 +03:00
Nekotekina
fb29933d3d
Add usz alias for std::size_t
2020-12-18 12:23:53 +03:00
Nekotekina
36c8654fb8
Remove HERE macro
...
Some cleanup.
Add location to some functions.
2020-12-10 12:30:22 +03:00
Nekotekina
e055d16b2c
Replace verify() with ensure() with auto src location.
...
Expression ensure(x) returns x.
Using comma operator removed.
2020-12-09 15:43:38 +03:00
RipleyTom
af8c661a64
Remove BOM markers
2020-12-06 15:30:12 +03:00
Megamouse
2cee26c3e7
Cleanup some includes
2020-10-31 11:53:46 +01:00
Nekotekina
cb0431d960
sys_fs/sys_usbd: add cpu_flag::wait
2020-10-30 20:14:32 +03:00
Nekotekina
4ff23a9943
sys_fs: fix file opening from /app_home
...
Typo.
2020-10-12 21:41:57 +03:00
Eladash
888b520b31
sys_fs: return ENOENT for relative paths
2020-10-03 19:09:09 +03:00
Nekotekina
ee00fdb61b
fs: improve handling root mountpoint
...
Path such as simply "/" falls into this category.
2020-10-02 14:37:58 +03:00
Nekotekina
9b22661c19
fs: improve mountpoint detection
...
Properly handle . and .. path components in mountpoint detection.
Remove app_home mountpoint and use mountpoint from argv[0] instead.
Add dev_root mountpoint for special purposes.
2020-10-02 12:32:35 +03:00
Eladash
b8fa6fb4c4
Win32 FS: Rewrite (fix) vfs::host::rename
2020-09-24 18:06:51 +03:00
Eladash
a21790b992
sys_fs: Fix sys_fs_disk_free
2020-09-19 13:53:04 +01:00
Eladash
762ceaf87e
sys_fs: Do not expose real hard drive available space!!!!!!!!!!!!!
2020-09-19 13:53:04 +01:00
Eladash
b31a0115b2
cellFsStat Improvements
2020-09-19 13:53:04 +01:00
Eladash
2483cc6f8d
Fix race in Crypto/unedat.cpp, Make NPDRM keys usage atomic
2020-06-28 23:26:10 +01:00
Eladash
0b24b09a06
sys_fs: Lock dev_hdd1 mount point at cellSysCacheClear
2020-04-04 19:36:16 +01:00
Eladash
a178374052
sys_fs: Limit NPDRM FDs to 16
...
Co-Authored-By: Silent <cookieplmonster@users.noreply.github.com>
2020-04-04 19:36:16 +01:00
Nekotekina
9dca2887d8
Fixup for Emu.Pause()
...
Remove some reduntant calls.
Don't pause on unknown sys_fs_fcntl operation.
2020-03-08 22:03:16 +03:00
Nekotekina
a166d3680e
Don't throw on invalid whence (return fs::error::einval)
2020-03-07 11:52:54 +03:00
Eladash
1669e95870
Implement lv2_file::open()
...
Return accurate error codes in prx_load_module, sys_spu_image_open and overlay_load_module.
2020-03-06 21:16:46 +03:00
Nekotekina Aux1
250736ece5
Fix warnings in emucore
2020-03-04 21:23:34 +03:00
Eladash
42a0512c66
cellSaveData: Avoid passing vm pointer to native API
2020-02-27 22:31:31 +03:00
Nekotekina
92e3eaf3ff
Fix signed-unsigned comparisons and mark warning as error (part 2).
2020-02-19 22:54:58 +03:00
Nekotekina
771eff273b
First part of fixing sign-compare warning (inside be_t).
2020-02-19 22:54:58 +03:00
Nekotekina
f08c778d2c
Use more starts_with/ends_with.
...
Remove ends_with global func.
2020-02-18 14:53:23 +03:00
Eladash
1915fe75a4
VSH: Stubs
2020-02-08 23:07:03 +03:00
Eladash
f05a3da964
Fix lv2_file::op_write regression
2020-01-21 16:45:41 +03:00
Nekotekina
3617f12a1e
sys_fs: avoid possible out of memory on file reads/writes
...
Use fixed-sized intermediate buffer.
2020-01-20 16:00:20 +03:00
Nekotekina
63f67c88cc
sys_fs: better stub sys_fs_fcntl(0xc0000006)
...
This syscall does something to classify filesystems by mountpoint.
2020-01-20 16:00:20 +03:00
Nekotekina
1b1b804d7e
sys_fs: add /dev_flash mountpoint
2020-01-20 16:00:20 +03:00
Nekotekina
55cb96ab3b
sys_fs: fix CELL_EIO condition in cellFsReadWithOffset
2020-01-20 16:00:20 +03:00
Eladash
14b99d9e8b
Write nread/nwrite in cellFsWrite/Read regardless of error checks
2020-01-18 15:56:05 +03:00
Nekotekina
e2512e78b6
sys_fs: always close locked file in sys_fs_close
...
Syscall returns EBUSY but succeeds nevertheless.
2020-01-17 00:24:07 +03:00
Nekotekina
a005090d3d
sys_fs: use constant in sys_fs_disk_free
2020-01-17 00:24:07 +03:00
Nekotekina
aeed349a99
sys_fs: adjust permissions for /dev_bdvd
...
Remove write permissions returned by stat, fstat, etc.
Also make sys_fs_open return CELL_EPERM on write attempt.
2020-01-11 04:48:42 +03:00
Nekotekina
8447d75dda
sys_fs: improve sys_fs_lsn_lock
...
It appears it does nothing only on /dev_hdd0 or /host_root (HOSTFS).
2020-01-11 03:44:52 +03:00
Nekotekina
fc6356a74c
sys_fs: adjust /dev_bdvd block size
...
From test.
2020-01-11 03:05:26 +03:00
Nekotekina
87cd653c6e
sys_fs: improve sys_fs_disk_free
...
Fix error codes and arg checks.
2020-01-11 01:10:50 +03:00
Nekotekina
7e35fd54a8
sys_fs: improve sys_fs_fcntl(0xc0000002)
...
Always obtain free space on /dev_hdd0.
2020-01-11 01:09:30 +03:00
Nekotekina
582ee80552
sys_fs: correct block size for /dev_hdd1
2020-01-10 05:24:43 +03:00
Nekotekina
0b4b87f069
sys_fs: fix sys_fs_get_block_size
...
Don't check file existence on /dev_hdd0.
Relax check on some mountpoints.
Fix CELL_EISDIR error condition.
2020-01-10 05:19:18 +03:00
Nekotekina
7523416a12
sys_fs: return CELL_ENOTSUP in sys_fs_fcntl(0xc0000006)
2020-01-09 04:15:20 +03:00
Nekotekina
9075208c80
sys_fs: fix logging in sys_fs_get_block_size
2020-01-09 04:15:20 +03:00
Nekotekina
d477889763
sys_fs: fix mountpoint detection
2020-01-09 04:15:20 +03:00
Nekotekina
f5cb147f8d
sys_fs: improve sys_fs_get_block_size values
...
Affected other syscalls:
sys_fs_fget_block_size
sys_fs_stat
sys_fs_fstat
sys_fs_fcntl (cellFsGetDirectoryEntries, cellFsGetFreeSize)
For default values:
Return sector_size = 512.
Return 4th arg = 512.
Fod /dev_bdvd:
Sector size = 2048.
Block size = 2048.
2020-01-07 23:16:17 +03:00
Nekotekina
63e669c0cf
sys_fs: fix sys_fs_fget_block_size
...
Return flags via last argument.
2020-01-07 21:55:19 +03:00
Nekotekina
9c54305e10
sys_fs: disable sys_fs_lsn_lock/unlock
...
According to test, nothing seems to happen.
Disable CELL_EBUSY errors associated with Stream Support API.
2020-01-07 21:55:19 +03:00
Nekotekina
f3d52de429
sys_fs: Adjust flags of /app_home mountpoint
2020-01-07 21:55:19 +03:00
Nekotekina
4450ae0c7a
sys_fs: fix CELL_FS_O_APPEND emulation
...
Don't use fs::append (not capable of).
Fix sys_fs_ftruncate (remove wrong workaround).
2020-01-05 18:15:55 +03:00
Nekotekina
9fc0aec066
sys_fs_stat: fix split file handling
...
Allow single-file case (consistently with sys_fs_open)
2020-01-05 18:15:55 +03:00
Nekotekina
bed2d558a6
sys_fs: implement CELL_EROFS error
...
Implement lv2_mp_flag::read_only.
Currently only /dev_bdvd is affected.
2020-01-05 18:15:55 +03:00
Nekotekina
d5f0957558
Implement lv2_fs_mount_point with mount point flags
...
Implement some actual mount points
Implement lv2_mp_flag::no_uid_gid
2020-01-05 18:15:43 +03:00
Eladash
872be25ed1
cellFs: Fix cellFsLseek with negative whence
2020-01-04 22:38:53 +03:00
Eladash
9d2c9e5d62
cellFs: Improve cellFsGetDirectoryEntries
2020-01-04 22:38:53 +03:00
Nekotekina
28fb0d1741
Fix lv2_fs_object::name
...
Recreate path from actual decoded components.
2020-01-04 21:44:03 +03:00
Nekotekina
0d629743ca
cellSysCache: poison opened cache files on cache clear
...
Make opened files return CELL_EIO after cache clear.
2019-11-09 14:50:41 +03:00
Nekotekina
ccf9543b44
Improve vfs::host::unlink on Windows (for sys_fs_rmdir)
...
Possibly fixes sys_fs_rmdir and other cases of directory removal.
Make sure the directory with deleted files always becomes empty.
For this purpose, temp files are moved to the root of the device.
2019-09-25 18:47:38 +03:00
Nekotekina
54952f6ad6
Use g_fxo for LoadedNpdrmKeys_t
...
Rename to loaded_npdrm_keys
2019-08-22 02:13:39 +03:00
eladash
1e5e0f3b5e
make sys_fs_closedir atomic
2019-07-29 21:55:59 +03:00
Nekotekina
2bc0ea37ab
sys_fs: yield PPU on disk access ops
2019-06-08 19:34:55 +03:00
Nekotekina
0d415407c7
sys_fs_unlink: add CELL_EISDIR check
2019-04-12 12:24:36 +03:00
Nekotekina
40142420c1
Implement vfs::host::unlink
...
Emulate POSIX behaviour in sys_fs_unlink.
This should allow to delete opened files transparently on Windows.
2019-04-10 13:58:12 +03:00
Nekotekina
9736773c04
Implement vfs::host::rename
...
With spurious access error workaround
2019-04-10 13:58:12 +03:00
elad
3c9f03968c
Yield before flushing io buffers in fsync (sys_fs) ( #5506 )
2019-03-08 16:07:14 +00:00
Nekotekina
522f5ea645
Fix cellFsGetFreeSize (following #5304 )
...
Simplify device name extraction
2018-12-24 16:04:46 +03:00
RipleyTom
077e710e3a
sys_fs_fcntl with parameter 0xC0000002 should extract device path from the given path and use that to gather free space information
2018-12-10 14:24:07 +03:00
eladash
4baa159523
cellFsOpen flag fix
2018-11-24 02:54:48 +03:00
eladash
57b7892de6
Fix typo in sys_fs_mkdir
...
create_path is a less resticted version of create_dir, it doesnt check for EEXIST for one.
2018-11-12 13:28:58 +03:00
Nekotekina
b94e98aed5
Rewrite sys_fs_opendir
...
Rewrite lv2_dir object
Support split files and mount points
2018-09-15 17:18:40 +03:00
Nekotekina
e8b5555630
Rewrite vfs::get and vfs::mount
...
Preprocess . and .. correctly
Don't use recursive locking
Also use std::string_view
Fix format system for std::string and std::string_view
Fix fmt::merge for std::string_view
2018-09-15 17:09:56 +03:00
Nekotekina
ca5158a03e
Cleanup semaphore<> (sema.h) and mutex.h (shared_mutex)
...
Remove semaphore_lock and writer_lock classes, replace with std::lock_guard
Change semaphore<> interface to Lockable (+ exotic try_unlock method)
2018-09-03 23:00:36 +03:00
Nekotekina
8abe6489ed
Mega-cleanup for atomic_t<> and named bit-sets bs_t<>
...
Remove "atomic operator" classes
Remove test, test_and_set, test_and_reset, test_and_complement global functions
Simplify atomic_t<> with constexpr if, remove some garbage
Redesign bs_t<> to use class, mark its methods constexpr
Implement atomic_bs_t<> for optimizations
Remove unused __bitwise_ops concept (should be in other header anyway)
Bitsets can now be tested via safe bool conversion
2018-09-03 21:40:36 +03:00
Nekotekina
c49c7de427
sys_fs_stat: support split files
...
Was forgotten after sys_fs_open
2018-08-30 14:56:45 +03:00
Nekotekina
363811981d
Reintroduce LOG_CHANNEL
...
Groundwork for further improvements
2018-08-25 15:39:00 +03:00
Nekotekina
62f9a2dc4b
sys_fs_open: support split files
2018-08-14 15:14:06 +03:00
scribam
1ae724f739
sys_fs: returns the correct error value when the path is 0 or an empty string
2018-03-23 21:45:22 +04:00
Robbie
00b1ff752d
Add flag for rockband. Tests have shown it independent other flags. But, actual use is currently not known.
2018-02-18 04:29:41 +04:00
Nekotekina
cce0ad0c35
Clean vm::ps3 namespace use
2018-02-09 17:49:37 +03:00
Ofek
a6208d2bd7
Reset initial seek position in MSELF files ( #3977 )
2017-12-23 23:18:55 +04:00
Zion
17bfb3beaf
various memory access violation fixes (and friends) ( #3930 )
...
* various memory access violation fixes
* Another fix, for motorstorm demo
* Better stub cellGameUpdateCheckStartAsync and FinishAsync, Fixes #3934
2017-12-16 04:03:49 +04:00
Nekotekina
74c248150b
Log sys_fs_utime values
2017-11-23 18:38:05 +03:00
Nekotekina
5b19908996
Escape problematic characters in VFS
...
With full-width <>:"\|?*
2017-10-11 22:01:37 +03:00
Nekotekina
5c93acefd9
Try to fix some fs errors
2017-09-19 15:07:07 +03:00