BlueSmarties the term used has changed slightly to 'DNACPR': Do not attempt cardiopulmonary resuscitation. The reason for this is that DNR (do not resuscitate) was deemed to give the impression that resuscitation, which is a violent and traumatic procedure, was something that was bound to succeed.
The legal status is that medical staff have the right to decide whether they will attempt resuscitation, unless there is a legal directive stating otherwise (such as an Advance Directive). Even if there is an Advance Directive, the team caring for the patient can't act on it (or rather, not act) unless they have actually seen it. So, in the event of cardiac arrest, if someone shouted 'Stop! Tony didn't want to be resuscitated and he has an advance directive!' then staff would be obliged to continue resuscitation attempts until such time as they see the advance directive. Which is why it's so important to sort that stuff out as soon as possible.
Medics will spend a lot of time discussing the prognosis for a patient, what avenues of treatment could be given and why they believe there should be a 'ceiling of intervention'. It gets very complicated. So in ICU we could have a patient that is 'for' BiPAP, not for Filtration, not for intubation and not for CPR. We could have another patient who is for everything except intubation and ventilation....the list goes on.
Ultimately, it is a medical decision and the responsibility lies with the Consultant the patient is assigned to.
These decisions are never taken lightly, though, and it's not unusual for a Consulant to ask for a review with one or two other Consultants to help them decide where the 'ceiling of intervention' is.