When assigning a profile to a new machine in Software management you receive an error :
Could not assign profile because it is currently using Patch Management.
The referenced machines are not disabled from Patch management.
Disconnect from Patch management.
If this step gives you the below error, you will have to remove the patch policies associated with it.
This is found under Patch management> Patch Policy > Membership.
You can also run this sql query to find out the which patch management settings have been assigned to the machines.