In general for more minor surgical procedures such as dental work and ambulatory surgical procedures I would continue the buprenorphine and compliment with acetaminophen and NSAIDs. If the buprenorphine dose is low I would increase temporarily as needed. For patients who need major surgery, I would discuss their pain management prior to the surgery. If they are concerned about pain, I would taper them off buprenorphine (not completely), use the full agonist for pain and afterwards return them to their full dose of buprenorphine.
My opinion is that it is illegal. The Drug Treatment Act of 1972 and the DATA 2000 makes it clear that there are two medications that are currently approved by the FDA for the maintenance and withdrawal management of opioid use disorder. The first is methadone which has been in use for the past fifty years. The other drug that can be used is the sublingual formulations of buprenorphine. The use of any other opioid product to treat opioid use disorder doesn’t meet the criteria and is therefore not allowed.