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
Robert Baldyga
de060d1d5b
Merge pull request #1307 from mmichal10/kmemleak
...
Integrate kmemleak into CAS
2022-10-04 10:03:37 +02:00
Robert Baldyga
64420d7ce7
Remove blkdev_can_hndl_bio() function
...
This check will always return 0, as none of kernel versions supported
by Open CAS sets a barrier flag in for bio. Those flags are exclusive to
struct request, which is no longer used by Open CAS.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-27 16:39:33 +02:00
Robert Baldyga
ec7cee7e75
Merge pull request #1352 from robertbaldyga/exp_obj-refactor
...
Refactor disk/exp_obj API
2022-09-27 10:11:57 +02:00
Michal Mielewczyk
38bef1f7fe
Integrate kmemleak into CAS
...
Kmemleak is a tool which allows to detect memory leaks in kernel. It requires
`CONFIG_DEBUG_KMEMLEAK` to be enabled during kernel compilation. Otherwise all
the kmemleak_* functions are NOPs.
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-09-26 15:44:16 +02:00
Robert Baldyga
5e2c1c15cf
Merge exp obj create/activate
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-23 14:21:37 +02:00
Robert Baldyga
d0d17545eb
Move major/minor management to exported object code
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-23 14:21:37 +02:00
Robert Baldyga
61dff1f6fd
Move private field to struct cas_exp_obj
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-23 14:21:37 +02:00
Robert Baldyga
dc390adf49
Move exported object specific properties to struct cas_exp_obj
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-23 14:21:37 +02:00
Robert Baldyga
72cf855355
Move openers_lock to struct cas_exp_obj
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-23 14:21:37 +02:00
Robert Baldyga
67ed36ae0e
Remove disk kobj
...
Simplify disk life cycle.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-23 14:21:37 +02:00
Robert Baldyga
2f54aea87d
Remove exported object kobj
...
Simplify exported object lifecycle.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-23 14:21:36 +02:00
Robert Baldyga
ad783917d0
Remove one-liner helper functions
...
Those were not very helpful. Mostly made the code harder to read.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-23 14:20:47 +02:00
Robert Baldyga
1fe83b4972
Manage lifetime of exported object in top adapter
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-23 14:20:42 +02:00
Robert Baldyga
74c17d5115
Merge pull request #1351 from live4thee/fix-compile-error
...
cas_cache: fix compile error when set CAS_DEBUG_IO=1
2022-09-20 16:04:56 +02:00
Robert Baldyga
8945b482ce
Remove private parameter from cas_disk_open()
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-19 15:37:58 +02:00
Robert Baldyga
6d2266f7ee
Remove cas_disk_claim()
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-19 15:37:56 +02:00
David Lee
193f2c9a3a
cas_cache: fix compile error when set CAS_DEBUG_IO=1
...
Signed-off-by: David Lee <live4thee@gmail.com>
2022-09-19 19:21:43 +08:00
Robert Baldyga
4ed64582a6
Remove cas_disk from naming in code
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-19 10:38:21 +02:00
Robert Baldyga
edc293495d
Remove cas_disk.h
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-16 15:16:28 +02:00
Robert Baldyga
2aae800c45
Move helpers from headers to source files
...
Move helper functions that are used in only one source file to that file.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-16 15:16:28 +02:00
Robert Baldyga
a7370366cb
Remove unused functions
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-16 15:16:28 +02:00
Robert Baldyga
13d3decfa9
Consolidate modules
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-09-16 15:16:28 +02:00
Robert Baldyga
a03c577f59
Merge pull request #1319 from robertbaldyga/casdsk-remove-dead-code
...
Clean cas_disk out of dead code
2022-09-09 09:54:34 +02:00
Adam Rutkowski
aaab620c8d
use INIT_WORK_ONSTACK for work on stack
...
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-09-01 01:04:22 +02:00
Robert Baldyga
8eb512a743
Remove cas_disk symbol lookup
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-08-25 13:02:25 +02:00
Robert Baldyga
3102856025
Remove unused exported symbols from cas_disk
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-08-25 12:33:51 +02:00
Karolina Rogowska
4fc0c4f8bb
Merge pull request #1310 from pdebski21/fix_standby_detach_error_msg
...
Fix error message when CAS already is in standby detach state
2022-08-19 15:01:24 +02:00
Piotr Debski
9273b39d5d
Fix error message for cache already in standby detach state
...
Signed-off-by: Piotr Debski <piotr.debski@intel.com>
2022-08-19 12:36:22 +02:00
Krzysztof Majzerowicz-Jaszcz
e997f768b0
Rework for RHEL8.5
...
Rework for RHEL8.5 compatibility to avoid potential bug of exiting queue
after IO completion on a different CPU.
Targeted RHEL kernel version corrected.
Signed-off-by: Krzysztof Majzerowicz-Jaszcz <krzysztof.majzerowicz-jaszcz@intel.com>
2022-08-16 13:50:59 +02:00
Krzysztof Majzerowicz-Jaszcz
b983eeb751
RHEL8.5 kernel 4.18 support fix
...
This patch adds support for RHEL8.5 with kernel 4.18.0.348.2.1.el8 and
later.
Additional request queue operations added for these kernels.
Configure scripts added/updated.
Fixes #1278
Signed-off-by: Krzysztof Majzerowicz-Jaszcz <krzysztof.majzerowicz-jaszcz@intel.com>
2022-08-12 08:52:36 +02:00
Krzysztof Majzerowicz-Jaszcz
bd9548cff4
Potential double IO completion fix
...
In specific circumstances, IO could be completed twice.
This patch fixes this problem.
Signed-off-by: Krzysztof Majzerowicz-Jaszcz <krzysztof.majzerowicz-jaszcz@intel.com>
2022-08-10 11:28:43 +02:00
Piotr Debski
dd95c8be4d
Add core, try-add script missing core-id parameter fix
...
Signed-off-by: Piotr Debski <piotr.debski@intel.com>
2022-07-12 11:14:44 +02:00
Robert Baldyga
c3f5a209c0
Merge pull request #1246 from robertbaldyga/dev-conf-lifecycle-fix
...
Fix device config life cycle management
2022-06-27 12:04:23 +02:00
Krzysztof Majzerowicz-Jaszcz
2739d83bec
Fix for null pointer dereference bug
...
Null pointer dereference occurs when terminating cache is standby detached state.
This fixes this problem.
Fixes #1235
Signed-off-by: Krzysztof Majzerowicz-Jaszcz <krzysztof.majzerowicz-jaszcz@intel.com>
2022-06-24 06:06:49 -04:00
Robert Baldyga
f2adc702e7
Fix device config life cycle management
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-06-24 08:52:32 +02:00
Michal Mielewczyk
d9e643a41a
Leave space for terminating buffers with null
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-06-24 08:05:11 +02:00
Robert Baldyga
7e6c8b97d7
Fix required memory check in the fallback path
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-06-22 20:41:27 +02:00
Jan Musial
6771f54b69
Use new OCF volume API
...
Signed-off-by: Jan Musial <jan.musial@intel.com>
2022-06-09 12:54:32 +02:00
Krzysztof Majzerowicz-Jaszcz
12ddca1cf3
OpenCAS Linux kernel 5.15 adaptation
...
This patch adapts OpenCAS Linux to compile and work with kernel v5.15
Commit id's from the kernel affecting OpenCAS:
commit 0e0ccdecb3cff95a350b4364e7ebbaa754d0e47d
block: remove bdget_disk
commit 9c2b9dbafc067e173db30c4fd0636392d27944e8
block: remove alloc_disk and alloc_disk_node
commit a8698707a1835be3abd12a3b28079a80999f8dee
block: move bd_mutex to struct gendisk
commit 2cece3778475abc855084d897a3cf61249798ad9
scsi: scsi_ioctl: Remove scsi_req_init()
commit 2f4731dcd0bb73379fbb9e3eb07ae7324125caef
block: remove bdput
commit 14cf1dbb55bb07427babee425fd2a8a9300737cc
block: remove bdgrab
Signed-off-by: Krzysztof Majzerowicz-Jaszcz <krzysztof.majzerowicz-jaszcz@intel.com>
2022-06-09 08:49:32 +02:00
Piotr Debski
f773d7fff3
standard error message for each disallowed management operation in standby mode
...
Signed-off-by: Piotr Debski <piotr.debski@intel.com>
2022-04-25 23:47:52 +02:00
Robert Baldyga
8fae9e2476
Destroy exp obj workqueue properly
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-04-08 17:16:04 +02:00
Adam Rutkowski
5bcba78e7f
Make sure classifier string is null terminated
...
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-04-08 16:42:25 +02:00
Michal Mielewczyk
531c7856bd
Prevent uninitialized value
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-04-08 16:42:25 +02:00
Michal Mielewczyk
68cadd90f8
Destroy volume if it couldn't be opened
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-04-08 16:42:25 +02:00
Robert Baldyga
737d19f00d
Wait for cleaner thread completion before destroying priv
...
_cas_stop_thread() function synchronizes with cleaner thread, so after
that we can be sure that there are no more ongoing cleaning requests.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-04-07 14:07:06 +02:00
Robert Baldyga
df36c027a6
Do not destroy expobj_wq if destroying exporting object failed
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-03-31 21:36:27 +02:00
Michal Mielewczyk
fb97333688
Don't remove core exported objects on standby stop
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-03-29 09:40:28 +02:00
Robert Baldyga
f73ab567ee
Merge pull request #1136 from robertbaldyga/cache-mode-standby-error
...
Return error on cache mode change in standby mode
2022-03-28 14:33:08 +02:00
Robert Baldyga
4ca0eb0530
Merge pull request #1135 from robertbaldyga/core-remove-fixes
...
Core remove fixes
2022-03-28 13:51:44 +02:00