Fix incompatible Storwize/SVC commands.

Inconsistencies in the command line syntax between Storwize/SVC
models and firmware versions caused driver failures. This patch
makes commands compatible to fix driver crashes on the V3700 and
controllers with firmware version 6.3.

Cherry-picked from f38f943899ea95fe237be1d096ceafd35b57a843

Change-Id: I51d5b97afa5419cdbf488f9e4e4597d22bb22f20
Fixes: bug 1163754
Fixed: bug 1163964
Fix AttributeError typo

Fixes Bug LP #1186566

Change-Id: I8211d365c4d3532cd6ffc3b3041661ff6b9e637f
Storwize/SVC: fix attach bug for live migration.

Add force flag for mkvdiskhostmap command to allow multi host mapping

Change-Id: I290a5986b213a0aaeae0d0ea0ad57350c9dee3c9
Fixes: bug #1179773
(cherry picked from commit 88c8b42194333566c085489b160d77fc71b61b86)
Bump stable/grizzly next version to 2013.1.3

Change-Id: I5bd6517f2db52cf8d94ea09703cadefdea83a2ff
Remove superfluous sf_volume_id reassignment

sf_volume_id was being reassigned after a new API call introduced
by a backported fix. This new API call (ModifyVolume) does not
contain the volumeID in its result.

Cloning a volume wasn't possible anymore due to a thrown error:
  KeyError: 'volumeID'

Removing the superfluous reassignment fixes the problem: sf_volume_id
is already assigned with the correct value.

Fixes: bug #1188454
Change-Id: I75196fc68666f28ac6222f43ea2ca6089b782f3f
Fix 'undefined symbol conn' error

Use self.conn, not conn.

Fixes LP Bug #1188619

Change-Id: Idbd62016fda4cafb6df953ca57af94d56edd3918
Fix incorrect authorization rule in quota contrib api.

Incorrect policy and authorization extension name in
 contrib quota api. Legacy from nova.

Change-Id: Ida8262ad63d6f881dd50a385a9913c2ed57b441c
Fixes: bug #1185974
(cherry picked from commit f7d4210d7c6c4c2f6f78f24d1681a110f49550d4)
Merge "Fix AttributeError typo" into stable/grizzly
Merge "Remove superfluous sf_volume_id reassignment" into stable/grizzly
Add _create_volume to ThinLVMVolumeDriver

Previously, _create_volume from LVMISCSIDriver would be called
when the volume manager calls create_volume_from_snapshot.

Fixes bug: 1192601

(cherry picked from commit 79a402d07502ac34bc0ec485b21b0be50ba807a7)

Conflicts:
	cinder/volume/drivers/lvm.py

Change-Id: I5cca287e8204c4647a5f09df961d9a76d0b38c42
Handle ECONNREFUSED exception in SolidFire driver.

The SolidFire driver wasn't handling connection exceptions
during init (capacity updates from scheduler).

This patch add a try/except wrap around the two places
that this is called and logs and error rather than crashing
cinder-volume service.

Fixes bug: 1195910

Change-Id: I30347cc0973bbf9dbc30ea02e204560095fc75b4
(cherry picked from commit d596bfe6562307343858f419062756640000b0c8)
solidfire: Add ability to override account prefix

The SolidFire account is created with a prefix based on the hostname
of the host running cinder-volume. This prevents cinder-volume from
being run in an active/active setup.

This patch introduces a new configuration option sf_account_prefix
to override the prefix used when a SolidFire account is created.

If sf_account_prefix is empty, no prefix will be added to
the SolidFire account name when created.

The default value is still the hostname.

Change-Id: I3b974789ea3e749cc8696b69754023ad76155179
Fixes: bug #1179671
(cherry picked from commit f9fd91e05e7d8d4a7d3a4659ba3c0ebd483732e1)
Merge "Storwize/SVC: fix attach bug for live migration." into stable/grizzly
Modify check for volume-type-id to a get w/default

While implementing Fix for a previous bug to enable setting
volume type on a cloned volume and reading it's info we added
a vref['volume_type_id'], problem is that the _do_clone method
is shared for both clone and create from snapshot.

In the create from snapshot case however that key doesn't exist
in the vref (which is a snapshot object).

This change turns this into a key.get with a default return.

Fixes bug: 1192745

Change-Id: I1a6d38de614f54fcaa31ea7cc4250aacc85b0796
(cherry picked from commit 48389857d15c5cda860fa8f9914d62b148bfd17a)
Merge "Fix incorrect authorization rule in quota contrib api." into stable/grizzly
Unbreak test_storwize_svc.py by setting storwize_svc_multihostmap_enabled

Fixes LP bug 1198146

Change-Id: Ia711457b9066d07458fd086df8b317c616f7baf9
Merge "Unbreak test_storwize_svc.py by setting storwize_svc_multihostmap_enabled" into stable/grizzly
Merge "Fix incompatible Storwize/SVC commands." into stable/grizzly
Merge "Modify check for volume-type-id to a get w/default" into stable/grizzly
Catch additional connect fail cases.

When fixing bug/1195910, some other failure
cases weren't considered (ie not authorized,
unreachable dest etc).

We should fix this up to handle the various
connection error states accordingly and also
add some hints to the log output to help
determine where to look in case of failure.

Fixes bug: 1201592

Change-Id: Ib099c7af705e7c49be4d0f723c8a20262c942e7f
(cherry picked from commit 5edbc4eb9a6b0d50612fffb6261850c80515b483)