Robert Baldyga
7ce5b7e68f
Merge pull request #1531 from mmichal10/fix-make-req-type
...
configure framework: detect make_req_fn type
2024-10-02 10:33:27 +02:00
Michal Mielewczyk
f34328adf2
Disable cache attach and detach
...
The feature is disable due to a possible data corruption which may occur when
attaching a new caching device. Once the problem is resolved this commit should
be reverted
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
2024-09-26 17:02:50 +02:00
Michal Mielewczyk
cefa6ab121
Add missing volume_destroy() in attach
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
2024-09-26 17:02:50 +02:00
Michal Mielewczyk
8fbbf31734
configure framework: detect make_req_fn type
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
2024-09-25 15:59:21 +02:00
Robert Baldyga
4bb4b914cb
Remove unneeded ifdefs
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-20 18:03:06 +02:00
Robert Baldyga
1e80f2d0c2
Update after removing struct ocf_io
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-13 12:38:26 +02:00
Robert Baldyga
5820e17e21
Drop support for submit_* ops
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-13 12:38:26 +02:00
Robert Baldyga
bc7710fb7d
Provide forward ops in block volume implementation
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-13 12:36:10 +02:00
Michal Mielewczyk
e7d7064341
Fix checking user param
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
2024-09-11 11:04:20 +02:00
Robert Baldyga
ded760a760
Fix debug macros
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 15:08:37 +02:00
Roel Apfelbaum
6367a66a68
Fix comment referring to old name of CAS control device
...
Signed-off-by: Roel Apfelbaum <roel.apfelbaum@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 15:08:37 +02:00
Michal Mielewczyk
72026cea63
Add missing ocf_volume_destroy() on cache init
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 15:08:37 +02:00
Michal Mielewczyk
6a409a0064
Set mngt queue to null if couldn't start thread
...
This prevents attempt to deinitialize the queue for the second time in
the start rollback
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 15:08:37 +02:00
Michal Mielewczyk
72594436ce
Don't access cache priv before locking cache
...
Cache priv may be freed by concurrent stop.
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 15:08:37 +02:00
Michal Mielewczyk
79a73fded2
ctx: Remove unused zalloc ops
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 15:08:37 +02:00
Ian Levine
c9f301249e
Check memory parameters before copying to user space
...
Signed-off-by: Ian Levine <ian.levine@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 15:08:16 +02:00
Michael Lyulko
ef22115539
Change compiler flags from -O2 to -Ofast
...
Signed-off-by: Michael Lyulko <michael.lyulko@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 14:36:43 +02:00
Toby Roth
988ac5f645
Do not submit IO in complete flush
...
Signed-off-by: Toby Roth <toby.roth@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 14:36:43 +02:00
Jan Musial
ab81ac667b
Remove unused fields
...
Signed-off-by: Jan Musial <jan.musial@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 14:36:43 +02:00
Gal Hammer
b9110635c1
cas_cache: fix "blk_update_request: operation not supported" error
...
A write request with the REQ_RAHEAD flag enabled cause the nvme driver
to send a write command with access frequency value that is reserved
(at least on specification version 1.4c). NVME devices might fail this
write command with an unsupported error. So we now clear the request's
flag based on its direction.
Signed-off-by: Gal Hammer <gal.hammer@huawei.com>
Signed-off-by: Shai Fultheim <shai.fultheim@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-10 14:36:43 +02:00
Michal Mielewczyk
16690e1eab
Enable cache detach
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
Signed-off-by: Jan Musial <jan.musial@huawei.com>
2024-09-09 16:30:05 +02:00
Michal Mielewczyk
af8c75b20a
Enable cache attach
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
Signed-off-by: Rafal Stefanowski <rafal.stefanowski@huawei.com>
2024-09-09 16:29:21 +02:00
Michal Mielewczyk
8724c29413
Disable changing cache params for detached cache
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
2024-09-09 15:57:35 +02:00
Michal Mielewczyk
bb8fc64ed5
Enable adding core to detached cache instance
...
Instead of trying to access properties of potenially unavaliable cache device
use properties saved in cache priv
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
2024-09-09 15:57:35 +02:00
Michal Mielewczyk
cef13315d0
Compare properties of a new cache device during cache attach
...
New cache device must have all the same properties then the previously
attached one.
Keeping cache properties in cache priv also allows to add new cores to
detached cache instance.
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
Signed-off-by: Rafal Stefanowski <rafal.stefanowski@huawei.com>
2024-09-09 15:57:35 +02:00
Michal Mielewczyk
e0ef8c1b8d
New error codes
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
2024-09-09 15:57:35 +02:00
Michal Mielewczyk
853e8f9357
configure: refactor cas_copy_queue_limits()
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
2024-09-09 15:57:35 +02:00
Michal Mielewczyk
33721e7c92
Set NOMERGES flag for cache volume
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
Signed-off-by: Rafal Stefanowski <rafal.stefanowski@huawei.com>
2024-09-09 15:57:30 +02:00
Robert Baldyga
08e9f1a323
Remove ocf_queue_get_cache()
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-09 14:48:44 +02:00
Robert Baldyga
f0727cce62
Merge pull request #1503 from mmichal10/block-standy
...
Block standby
2024-09-09 11:16:42 +02:00
Michal Prager
f1ffd7af80
Update needed RAM calculation method
...
Signed-off-by: Michal Prager <michal.prager@huawei.com>
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-06 15:47:26 +02:00
Michal Mielewczyk
0f0ef79b89
Disable standby mode
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com>
2024-09-06 13:23:07 +02:00
Robert Baldyga
d605ab48c8
Update mngt queue creation API
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-05 16:07:37 +02:00
Robert Baldyga
20ad0478c8
rpool: Mark an entry for kmemleak outside of atomic context
...
The kmemleak_alloc() function can sleep, thus should not be called
under spinlock. This patch fixes bug occurring on debug kernel with
kmemleak enabled.
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-09-02 12:16:59 +02:00
Robert Baldyga
2bcb220a03
Fix redefined macro error
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-07-22 15:53:10 +02:00
Robert Baldyga
4b693a5ecd
Fix compilation on RHEL <9.x
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-07-11 15:19:11 +02:00
MohammadJavad Asadi
b4a1e9aac3
Fix compile on Rockylinux 9
...
Signed-off-by: MohammadJavad Asadi <mj.asadi72@gmail.com>
2024-06-22 13:37:54 +03:30
Robert Baldyga
b9aa65f254
Add support for Linux kernel up to 6.8
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-05-14 08:47:45 +02:00
Tamar Levovitz
a202d8c9f5
Add support for Linux kernel up to 6.5
...
Signed-off-by: Tamar Levovitz <tamar.levovitz@huawei.com>
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-05-14 08:47:21 +02:00
Robert Baldyga
9fc5e39349
Get rid of strlcpy()
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-05-14 08:22:34 +02:00
Robert Baldyga
5c4b5634cb
Add missing "static" to the local functions
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-05-14 08:22:34 +02:00
Robert Baldyga
7dd5fa8029
Add missing headers
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-05-14 08:22:34 +02:00
Robert Baldyga
6aa30f05ce
Remove unused function
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-05-14 08:22:34 +02:00
Robert Baldyga
334cc31a5c
Set exp_obj rotational=0
...
Signed-off-by: Robert Baldyga <robert.baldyga@huawei.com>
2024-04-03 12:11:42 +02:00
Robert Baldyga
9db73b2fb6
Set gd->queue to NULL after queue cleanup
...
Otherwise put_disk() tries to access the queue which leads to
kernel panic.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-12-30 15:18:07 +01:00
Michal Mielewczyk
4753374b1b
Change CAS_BIO_MAX_VECS value
...
Previously when user tried to allocate to big bio he recieved NULL. As the
behavior was changed to `BUG()` passing out of range value is no longer legal.
Limiting the requested bio size to BIO_MAX_PAGES (on the older kernels) or to
BIO_MAX_VECS (on the newer ones) eliminates the problem as the macros represent
the max possible value.
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-12-28 13:59:20 +01:00
Krzysztof Majzerowicz-Jaszcz
2eef5ce36b
Fix for using uninitialized variable in printk
...
This commit fixes the case of using unintialized variable in error
handling path after failed core addition.
Signed-off-by: Krzysztof Majzerowicz-Jaszcz <krzysztof.majzerowicz-jaszcz@intel.com>
2022-11-08 11:47:23 +00:00
Krzysztof Majzerowicz-Jaszcz
f1bf2eb909
Kernel 6.0 support
...
This patch introduces kernel 6.0 support for Open CAS
Signed-off-by: Krzysztof Majzerowicz-Jaszcz <krzysztof.majzerowicz-jaszcz@intel.com>
2022-10-28 09:41:43 +02:00
Robert Baldyga
cefaa3b415
Merge pull request #1380 from robertbaldyga/available-memory-check
...
Use available memory statistic when possible
2022-10-25 11:04:15 +02:00
Krzysztof Majzerowicz-Jaszcz
f0af7cb52d
Open CAS Linux kernel 5.18 support
...
This patch introduces the support for 5.18 kernel.
Signed-off-by: Krzysztof Majzerowicz-Jaszcz <krzysztof.majzerowicz-jaszcz@intel.com>
2022-10-24 09:53:01 +00:00