~~~~
First things first, BDSM isn’t banned in Canada. However, it emerged during the Jian Gomeshi trial that the Crown considers that there is a limit to what can be considered consensual sexual acts. IIRC the courts judged that individuals cannot consent to being seriously harmed (Gomeshi’s defense was that his victims consented to his acts) and that there is a point at which BDSM practices may be considered to turn into assault. I’m not too sure on the specifics or the factors taken into consideration, but I think that’s the argument.
The story about books being confiscated by authorities has to do with the laws regarding the importation of goods into Canada, such as books, movies, etc. that are considered obscene. CBSA have rights to overrule certain sections of the charter of rights and freedoms when it comes to preventing obscene material from entering the country. Of course, the CBSA has to prove the validity of its claim in court.
You can read up about that here (the memorandum specifically cites the case you mention as part of its service standard) :
https://www.cbsa-asfc.gc.ca/publications/dm-md/d9/d9-1-1-eng.html
The memorandum contains sections that describe the standards tests to determine what is or isn’t considered obscene in Canada.
I hope that helps.