Only set up the qsd instance if the associated target is either a MDT
or a OST. We typically have no interest in setting up a QSD instance
on a standalone MGS.
Signed-off-by: Johann Lombardi <johann.lombardi@intel.com>
Change-Id: I0facb08feef0b36f141b749d7be538cbde5f1114
Reviewed-on: http://review.whamcloud.com/4203
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Niu Yawei <niu@whamcloud.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
{
struct qsd_thread_info *qti = qsd_info(env);
struct qsd_instance *qsd;
- int rc;
+ int rc, type, idx;
ENTRY;
+ /* only configure qsd for MDT & OST */
+ type = server_name2index(svname, &idx, NULL);
+ if (type != LDD_F_SV_TYPE_MDT && type != LDD_F_SV_TYPE_OST)
+ RETURN(NULL);
+
/* allocate qsd instance */
OBD_ALLOC_PTR(qsd);
if (qsd == NULL)