func setTargetRAIDCfg(p *ironicProvisioner, raidInterface string, ironicNode *nodes.Node, data provisioner.PrepareData) (provisioner.Result, error) {
	err := ironic.CheckRAIDConfigure(raidInterface, data.TargetRAIDConfig)
	if err != nil {
		return operationFailed(err.Error())
	}
	var logicalDisks []nodes.LogicalDisk
	logicalDisks, err = ironic.BuildTargetRAIDCfg(data.TargetRAIDConfig)
	if err != nil {
		return operationFailed(err.Error())
	}
	if len(logicalDisks) == 0 {
		return provisioner.Result{}, nil
	}
	if data.RootDeviceHints == nil {
		logicalDisks[0].IsRootVolume = new(bool)
		*logicalDisks[0].IsRootVolume = true
	} else {
		p.log.Info("rootDeviceHints is used, the first volume of raid will not be set to root")
	}
	err = nodes.SetRAIDConfig(
		p.client,
		ironicNode.UUID,
		nodes.RAIDConfigOpts{LogicalDisks: logicalDisks},
	).ExtractErr()
	if err != nil {
		return transientError(err)
	}
	return provisioner.Result{}, nil
}
setTargetRAIDCfg set the RAID settings to the ironic Node for RAID configuration steps
package ironic
import (
	"github.com/gophercloud/gophercloud/openstack/baremetal/v1/nodes"
	"github.com/metal3-io/baremetal-operator/pkg/ironic"
	"github.com/metal3-io/baremetal-operator/pkg/provisioner"
)