- 24 2月, 2016 1 次提交
-
-
由 Sumit Saxena 提交于
This patch will do proper error handling for DCMD timeout failure cases for Fusion adapters: 1. For MFI adapters, in case of DCMD timeout (DCMD which must return SUCCESS) driver will call kill adapter. 2. What action needs to be taken in case of DCMD timeout is decided by function dcmd_timeout_ocr_possible(). DCMD timeout causing OCR is applicable to the following commands: MR_DCMD_PD_LIST_QUERY MR_DCMD_LD_GET_LIST MR_DCMD_LD_LIST_QUERY MR_DCMD_CTRL_SET_CRASH_DUMP_PARAMS MR_DCMD_SYSTEM_PD_MAP_GET_INFO MR_DCMD_LD_MAP_GET_INFO 3. If DCMD fails from driver init path there are certain DCMDs which must return SUCCESS. If those DCMDs fail, driver bails out. For optional DCMDs like pd_info etc., driver continues without executing certain functionality. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
-
- 10 11月, 2015 1 次提交
-
-
由 Sumit Saxena 提交于
Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
-
- 29 10月, 2015 7 次提交
-
-
Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
-
Remove PCI id based checks and use instance->ctrl_context to decide whether controller is MFI-based or a Fusion adapter. Additionally, Fusion adapters are divided into two categories: Thunderbolt and Invader. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
-
Syncro firmware supports round robin I/O switching on dual path. Driver uses validHandles to check for dual path. However, it is supposed to check for values > 1 (not > 2). Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
-
Fix the issue reported at: http://marc.info/?l=linux-scsi&m=143694494104544&w=2 Try to do chip reset at driver load time. If firmware fails to reach ready state, try chip reset using adp_reset() callback. For Fusion adapters the call back was previously void. Provide a suitable reset function. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
-
Driver will expose max sge = 256 (earlier it was 64) if firmware supports extended IO size (1M). Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NMartin Petersen <martin.petersen@oracle.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
-
Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NMartin Petersen <martin.petersen@oracle.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
-
Implemented JBOD map which will provide quick access for JBOD path and also provide sequence number. This will help hardware to fail command to the FW in case of any sequence mismatch. Fast Path I/O for JBOD will refer JBOD map (which has sequence number per JBOD device) instead of RAID map. Previously, the driver used RAID map to get device handle for fast path I/O and this not have sequence number information. Now, driver will use JBOD map instead. As part of error handling, if JBOD map is failed/not supported by firmware, driver will continue using legacy behavior. Now there will be three IO paths for JBOD (syspd): - JBOD map with sequence number (Fast Path) - RAID map without sequence number (Fast Path) - FW path via h/w exception queue deliberately setup devhandle 0xFFFF (FW path). Relevant data structures: - Driver send new DCMD MR_DCMD_SYSTEM_PD_MAP_GET_INFO for this purpose. - struct MR_PD_CFG_SEQ- This structure represent map of single physical device. - struct MR_PD_CFG_SEQ_NUM_SYNC- This structure represent whole JBOD map in general(size, count of sysPDs configured, struct MR_PD_CFG_SEQ of syspD with 0 index). - JBOD sequence map size is: sizeof(struct MR_PD_CFG_SEQ_NUM_SYNC) + (sizeof(struct MR_PD_CFG_SEQ) * (MAX_PHYSICAL_DEVICES - 1)) which is allocated while setting up JBOD map at driver load time. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NMartin Petersen <martin.petersen@oracle.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
-
- 26 8月, 2015 1 次提交
-
-
由 Bjorn Helgaas 提交于
Use dev_printk() when possible to make messages more useful. Signed-off-by: NBjorn Helgaas <bhelgaas@google.com> Reviewed-by: NHannes Reinecke <hare@suse.de> Acked-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
- 01 6月, 2015 1 次提交
-
-
megaraid_sas : Modify return value of megasas_issue_blocked_cmd() and wait_and_poll() to consider command status returned by firmware This patch is rebased on top of recently sent 18 patches(submitted by me) for megaraid_sas driver. Change the return value of wait_and_poll() and megsas_issue_blocked_cmd() based on MFI_STAT returned by firmware for that command. Earlier driver always send return type based on command completion (but never check MFI_STAT_OK for that command), so even if command is failed by firmware still driver will return SUCCESS status from these functions wait_and_poll() and megsas_issue_blocked_cmd() and if caller of these functions does not check command status (MFI_STAT), then it may endup using invalid data returned in DMA buffers(one of the example is megasas_ld_list_query DCMD). Best thing to avoid this type of issue is do error handling and set proper return type from caller function wait_and_poll() and megsas_issue_blocked_cmd(). The change proposed in this patch will fix the regression introduced in patch- "90dc9d98 megaraid_sas : MFI MPT linked list corruption fix" inside function megasas_ld_list_query(). Prior to this MFI MPT linked list corruption fix patch, megasas_ld_list_query() function used to check DCMD status(returned by firmware) but with this linked list corruption fix patch, DCMD status will not be checked inside function megasas_ld_list_query() and introduced this issue of wrong data being used by function megasas_ld_list_query(). Cc: <stable@vger.kernel.org> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
- 26 5月, 2015 1 次提交
-
-
由 Geert Uytterhoeven 提交于
Fix typo in kerneldoc identifier. Signed-off-by: NGeert Uytterhoeven <geert+renesas@glider.be> Acked-by: NSumit Saxena <sumit.saxena@lsi.com> Cc: James E.J. Bottomley <JBottomley@parallels.com> Signed-off-by: NJiri Kosina <jkosina@suse.cz>
-
- 25 5月, 2015 9 次提交
-
-
由 Christoph Hellwig 提交于
The fusion HBAs don't really use the instance template like the other variants, as it branches off at a much higher level. So instead of trying to squeeze megasas_fire_cmd_fusion into the wrong calling convention call it locally with argument data types that match what is passed. [jejb: fix up 32 bit compile failure] Signed-off-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NHannes Reinecke <hare@suse.de> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
由 Christoph Hellwig 提交于
Signed-off-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NHannes Reinecke <hare@suse.de> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
由 Christoph Hellwig 提交于
Add noop conversions for all ones to make sparse happy. Signed-off-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NHannes Reinecke <hare@suse.de> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
由 Christoph Hellwig 提交于
This adds endianness annotations to all data structures, and a few variables directly referencing them. Signed-off-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NHannes Reinecke <hare@suse.de> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
This patch will add support for Single Server High Availability(SSHA) cluster support. Here is the short decsription of changes done to add support for SSHA- 1) Host will send system's Unique ID based on DMI_PRODUCT_UUID to firmware. 2) Toggle the devhandle in LDIO path for Remote LDs. Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NHannes Reinecke <hare@suse.de> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
megaraid_sas driver will use block layer provided tag for indexing internal MPT frames to get any unique MPT frame tied with tag. Each IO request submitted from SCSI mid layer will get associated MPT frame from MPT framepool (retrieved and return back using spinlock inside megaraid_sas driver's submission/completion call back). Getting MPT frame from MPT Frame pool is very expensive operation because of associated spin lock operation (spinlock overhead increase on multi NUMA node). This type of locking in driver is very expensive call considering each IO request need - Acquire and Release of the same lock. With this support, in IO path driver will directly provide the unique command index(which is based on block layer tag) and will get the MPT frame tied to the tag and this way driver can get rid off lock, which synchronizes the access to MPT frame pool while fetching and returning MPT frame from the pool. This support in driver provides siginificant performance improvement(on multi NUMA node system)on latest upstream with SCSI.MQ as well as on existing linux distributions. Here is the data for test executed at Avago- - IO Tool- FIO - 4 Socket SMC server. (4 NUMA node server) - 12 SSDs in JBOD mode . - 4K Rand READ, QD=32 - SCSI MQ x86_64 (Latest Upstream kernel) - upto 300% Performance Improvement. If IOs are running on single Node, perfromance gain is less, but as soon as increase number of nodes, performance improvement is significant. IOs running on all 4 NUMA nodes, with this patch applied IOPs observed was 1170K vs 344K IOPs seen without this patch. Logically, there are two parts of this patch- 1) Block layer tag support 2) changes in calling convention of return_cmd. part 2 will revert the changes done by patch- 90dc9d98 megaraid_sas : MFI MPT linked list corruption fix because changes done in part 1 has fixed the problem of MFI MPT linked list corruption. part 2 is very much dependent on part 1, so we decided to have single patch for these two logical changes. [jejb: remove chatty printk pointed out by hch] Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NHannes Reinecke <hare@suse.de> Reviewed-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
This patch will add separate function for refiring MFI commands in Fusion adapters's OCR code. Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NHannes Reinecke <hare@suse.de> Reviewed-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
- 17 4月, 2015 1 次提交
-
-
由 Christoph Hellwig 提交于
We only want to steer the I/O completion towards a queue, but don't actually access any per-CPU data, so the raw_ version is fine to use and avoids the warnings when using smp_processor_id(). Signed-off-by: NChristoph Hellwig <hch@lst.de> Reported-by: NAndy Lutomirski <luto@kernel.org> Tested-by: NAndy Lutomirski <luto@kernel.org> Acked-by: NSumit Saxena <sumit.saxena@avagotech.com> Cc: <stable@vger.kernel.org> Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
-
- 09 1月, 2015 6 次提交
-
-
1) For fusion adapters, limit reserved frames for non SCSI commands to 8 (3 for parallel IOCTLs + 5 for driver's internal DCMDs). Earlier reserved commands for non SCSI IO frames was set to 32, so with this implementation, increased per controller "can_queue". Behavior of MFI controllers will remain unchanged. 2) Optimize the code related to per controller's 'can_queue' setting. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NChaitra Basappa <chaitra.basappa@avagotech.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
Driver calls megasas_complete_cmd() to call wake_up() for each MFI frame that was issued through the ioctl() interface prior to the kill adapter. This ensures userspace ioctl() system calls issued just before a kill adapter don't get stuck in wait state and IOCTLs are returned to the application. Cc: <stable@vger.kernel.org> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NChaitra Basappa <chaitra.basappa@avagotech.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
Update driver "mask_interrupts" before enable/disable hardware interrupt in order to avoid missing interrupts because of "mask_interrupts" still set to 1 and hardware interrupts are enabled. Cc: <stable@vger.kernel.org> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NChaitra Basappa <chaitra.basappa@avagotech.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
This patch will address the issue of SCSI device created at OS level for non existing VD. ldTgtIdtoLd[] array has size 256 for Extended VD firmware and 128 for legacy firmware. Accessing indices beyond array size (OS will send TUR, INQUIRY.. commands upto device index 255), may return valid LD value and that particular SCSI command will be SUCCESS and creating SCSI device for non existing target(VD). For legacy firmware (64 VD firmware), invalidates LD (by setting LD value to 0xff) in LdTgtIdtoLd[] array for device index beyond 127, so that invalid LD(0xff) value should be returned beyond device index beyond 127. Cc: <stable@vger.kernel.org> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
This patch adds support for Secure Encrypting Drives (SED) in JBOD mode: 1) If the firmware supports SED JBOD, all non read/write commands to JBODs will be sent via firmware path, and read/write commands to JBODs will be sent via fastpath. 2) If the firmware does not support SED JBOD, driver will fall back to the old design, i.e. send all JBOD I/O via fastpath. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NChaitra Basappa <chaitra.basappa@avagotech.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
This patch addresses below issues: 1) Few endianness bug fixes. 2) Break the iteration after (MAX_LOGICAL_DRIVES_EXT - 1)), instead of MAX_LOGICAL_DRIVES_EXT. 3) Optimization in MFI INIT frame before firing. 4) MFI IO frame should be 256bytes aligned. Code is optimized to reduce the size of frame for fusion adapters and make the MFI frame size calculation a bit transparent and readable. Cc: <stable@vger.kernel.org> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NChaitra Basappa <chaitra.basappa@avagotech.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
- 24 11月, 2014 4 次提交
-
-
This patch addresses few endianness related bug fixes. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Cc: <stable@vger.kernel.org> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
In OCR(Online Controller Reset) path, driver sets adapter state to MEGASAS_HBA_OPERATIONAL before getting new RAID map. There will be a small window where IO will come from OS with old RAID map. This patch will update adapter state to MEGASAS_HBA_OPERATIONAL, only after driver has new RAID map to avoid any IOs getting build using old RAID map. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
In OCR (Online Controller Reset) path, driver sets adapter state to MEGASAS_HBA_OPERATIONAL before getting new RAID map. There will be a small window where IO will come from OS with old RAID map. This patch will update adapter state to MEGASAS_HBA_OPERATIONAL, only after driver has new RAID map to avoid any IOs getting build using old RAID map. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
Update MAINTAINERS list and copyright information for megaraid_sas driver. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
- 17 9月, 2014 8 次提交
-
-
Resending the patch. Addressed the review comments from Tomas Henzl. Added comment for to-do work. Problem statement: MFI link list in megaraid_sas driver is used from mfi-mpt pass-through commands. This list can be corrupted due to many possible race conditions in driver and eventually we may see kernel panic. One example - MFI frame is freed from calling process as driver send command via polling method and interrupt for that command comes after driver free mfi frame (actually even after some other context reuse the mfi frame). When driver receive MPT frame in ISR, driver will be using the index of MFI and access that MFI frame and finally in-used MFI frame’s list will be corrupted. High level description of new solution - Free MFI and MPT command from same context. Free both the command either from process (from where mfi-mpt pass-through was called) or from ISR context. Do not split freeing of MFI and MPT, because it creates the race condition which will do MFI/MPT list corruption. Renamed the cmd_pool_lock which is used in instance as well as fusion with below name. mfi_pool_lock and mpt_pool_lock to add more code readability. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
Resending the patch. Addressed the review comments from Tomas Henzl. Current driver does fast path read load balancing between arm and mirror disk for two Drive Raid-1 configuration only. Now, Driver support fast path read load balancing for all (any number of disk) Raid-1 configuration. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
Resending the patch. Addressed the review comments from Tomas Henzl. Round down the max sge to power of two. Earlier max sge limit is 70 SGE, which will allow block layer to send 280K IO frame. It is optimal to provide max IO size aligned to the smallest possible stripe size. E.a Consider that we have configured RAID Volumes which does not allow Fast Path across the stripe. Raid volume with stripe size = 256K, will have peformance hit if we get io frame of size 280K. Driver will not send IO frame large than stripe size to the Fast Path. Also, FW will convert 280K frame into 256K + 24K. This is an additional overhead. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
Resending the patch. Addressed the review comments from Tomas Henzl. reserved1 field(part of union) of Raid map struct was not required so it is removed. Current MegaRAID firmware and hence the driver only supported 64VDs. E.g: If the user wants to create more than 64VD on a controller, it is not possible on current firmware/driver. New feature and requirement to support upto 256VD, firmware/driver/apps need changes. In addition to that there must be a backward compatibility of the new driver with the older firmware and vice versa. RAID map is the interface between Driver and FW to fetch all required fields(attributes) for each Virtual Drives. In the earlier design driver was using the FW copy of RAID map where as in the new design the Driver will keep the RAID map copy of its own; on which it will operate for any raid map access in fast path. Local driver raid map copy will provide ease of access through out the code and provide generic interface for future FW raid map changes. For the backward compatibility driver will notify FW that it supports 256VD to the FW in driver capability field. Based on the controller properly returned by the FW, the Driver will know whether it supports 256VD or not and will copy the RAID map accordingly. At any given time, driver will always have old or new Raid map. So with this changes, driver can also work in host lock less mode. Please see next patch which enable host lock less mode for megaraid_sas driver. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
Resending the patch. Addressed the review comments from Tomas Henzl. Move buff_offset inside spinlock, corrected loop at crash dump buffer free, reset_devices check is added to disable fw crash dump feature in kdump kernel. This feature will provide similar interface as kernel crash dump feature. When megaraid firmware encounter any crash, driver will collect the firmware raw image and dump it into pre-configured location. Driver will allocate two different segment of memory. #1 Non-DMA able large buffer (will be allocated on demand) to capture actual FW crash dump. #2 DMA buffer (persistence allocation) just to do a arbitrator job. Firmware will keep writing Crash dump data in chucks of DMA buffer size into #2, which will be copy back by driver to the host memory as described in #1. Driver-Firmware interface: ================== A.) Host driver can allocate maximum 512MB Host memory to store crash dump data. This memory will be internal to the host and will not be exposed to the Firmware. Driver may not be able to allocate 512 MB. In that case, driver will do possible memory (available at run time) allocation to store crash dump data. Let’s call this buffer as Host Crash Buffer. Host Crash buffer will not be contigious as a whole, but it will have multiple chunk of contigious memory. This will be internal to driver and firmware/application are unaware of it. Partial allocation of Host Crash buffer may have valid information to debug depending upon what was collected in that buffer and depending on nature of failure. Complete Crash dump is the best case, but we do want to capture partial buffer just to grab something rather than nothing. Host Crash buffer will be allocated only when FW Crash dump data is available, and will be deallocated once application copy Host Crash buffer to the file. Host Crash buffer size can be anything between 1MB to 512MB. (It will be multiple of 1MBs) B.) Irrespective of underlying Firmware capability of crash dump support, driver will allocate DMA buffer at start of the day for each MR controllers. Let’s call this buffer as “DMA Crash Buffer”. For this feature, size of DMA crash buffer will be 1MB. (We will not gain much even if DMA buffer size is increased.) C.) Driver will now read Controller Info sending existing dcmd “MR_DCMD_CTRL_GET_INFO”. Driver should extract the information from ctrl info provided by firmware and figure out if firmware support crash dump feature or not. Driver will enable crash dump feature only if “Firmware support Crash dump” + “Driver was able to create DMA Crash Buffer”. If either one from above is not set, Crash dump feature should be disable in driver. Firmware will enable crash dump feature only if “Driver Send DCMD- MR_DCMD_SET_CRASH_BUF_PARA with MR_CRASH_BUF_TURN_ON” Helper application/script should use sysfs parameter fw_crash_xxx to actually copy data from host memory to the filesystem. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
Resending the patch. Addressed the review comments from Tomas Henzl. Current driver updates reply post host index to let firmware know that replies are processed, while returning from ISR function, only if there is no oustanding replies in reply queue. Driver will free the request frame immediately from ISR but reply post host index is not yet updated. It means freed request can be used by submission path and there may be a tight loop in request/reply path. In such condition, firmware may crash when it tries to post reply and there is no free reply post descriptor. Eventually two things needs to be change to avoid this issue. Increase reply queue depth (double than request queue) to accommodate worst case scenario. Update reply post host index to firmware once it reach to some pre-defined threshold value. This change will make sure that firmware will always have some buffer of reply descriptor and will never find empty reply descriptor in completion path. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
Resending the patch. Addressed the review comments from Tomas Henzl. Reduce the assingment for u64 req_data variable. Use writeq() for 64bit PCI write instead of writel() to avoid additional lock overhead. Signed-off-by: NSumit Saxena <sumit.saxena@avagotech.com> Signed-off-by: NKashyap Desai <kashyap.desai@avagotech.com> Reviewed-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-
由 Adam Radford 提交于
The following patch for megaraid_sas fixes a reset_mutex leak in megasas_reset_fusion(). Signed-off-by: NAdam Radford <aradford@gmail.com> Reviewed-by: NMartin K. Petersen <martin.petersen@oracle.com> Signed-off-by: NChristoph Hellwig <hch@lst.de>
-