crush: add is_valid_crush_name() helper

[A-Za-z0-9-_.]+

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Dan Mick <dan.mick@inktank.com>
crush: return EINVAL on invalid name from {insert,update,create_or_move}_item, set_item_name

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Dan Mick <dan.mick@inktank.com>
mon/OSDMonitor: return error if we can't set the new bucket's name

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Dan Mick <dan.mick@inktank.com>