Ignore:
Timestamp:
Mar 15, 2017, 2:42:58 AM (2 weeks ago)
Author:
brainslayer
Message:

use new squashfs in all kernels

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/linux/universal/linux-4.4/drivers/target/target_core_device.c

    r31390 r31662  
    7878
    7979                se_lun = rcu_dereference(deve->se_lun);
     80
     81                if (!percpu_ref_tryget_live(&se_lun->lun_ref)) {
     82                        se_lun = NULL;
     83                        goto out_unlock;
     84                }
     85
    8086                se_cmd->se_lun = rcu_dereference(deve->se_lun);
    8187                se_cmd->pr_res_key = deve->pr_res_key;
    8288                se_cmd->orig_fe_lun = unpacked_lun;
    8389                se_cmd->se_cmd_flags |= SCF_SE_LUN_CMD;
    84 
    85                 percpu_ref_get(&se_lun->lun_ref);
    8690                se_cmd->lun_ref_active = true;
    8791
     
    97101                }
    98102        }
     103out_unlock:
    99104        rcu_read_unlock();
    100105
     
    827832        rcu_assign_pointer(xcopy_lun->lun_se_dev, dev);
    828833        init_completion(&xcopy_lun->lun_ref_comp);
     834        init_completion(&xcopy_lun->lun_shutdown_comp);
    829835        INIT_LIST_HEAD(&xcopy_lun->lun_deve_list);
    830836        INIT_LIST_HEAD(&xcopy_lun->lun_dev_link);
Note: See TracChangeset for help on using the changeset viewer.